Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Strange behaviour when using glob in if condition

by yulivee07 (Sexton)
on Apr 11, 2017 at 13:21 UTC ( #1187638=perlquestion: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl -w
    
    ...
      remove_files_in_empty_directories($dir);
    }
    
  2. or download this
    /ecurep/hw/7/7042/21/EC/21EC3EC/.EcuRep-Lenovo_outofscope
    /ecurep/hw/7/7042/21/EC/21EC41C/.EcuRep-Lenovo_outofscope
    /ecurep/hw/7/7042/21/EC/21EC4DC/.EcuRep-Lenovo_outofscope
    
  3. or download this
    /ecurep/hw/7/7042/21/EC/21EC4DC/.EcuRep-Lenovo_outofscope
    
  4. or download this
    /ecurep/hw/7/7042/21/EC/21EC3EC/.EcuRep-Lenovo_outofscope
    /ecurep/hw/7/7042/21/EC/21EC41C/.EcuRep-Lenovo_outofscope
    
  5. or download this
    drwxr-s---    4 root     swsupt          512 Apr 08 04:53 21EC3EC
    drwxr-s---    4 root     swsupt          512 Apr 08 05:24 21EC41C
    ...
    -rw-r--r--    1 root     swsupt           25 Nov 04 05:26 .EcuRep-Leno
    +vo_outofscope
    drwxr-s---    2 root     swsupt          512 Mar 31 06:26 2017-03-31
    drwxr-s---    2 root     swsupt          512 Apr 07 06:26 2017-04-07
    
  6. or download this
    # makes no difference
    return if  glob "'${directory}/*'";
    ...
    return;
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://1187638]
Approved by haukex
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having an uproarious good time at the Monastery: (3)
As of 2023-12-02 02:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What's your preferred 'use VERSION' for new CPAN modules in 2023?











    Results (13 votes). Check out past polls.

    Notices?