Last modified: 2013-06-24 14:46:18 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T52097, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 50097 - take doesn't recurse properly
take doesn't recurse properly
Status: RESOLVED FIXED
Product: Wikimedia Labs
Classification: Unclassified
tools (Other open bugs)
unspecified
All All
: Unprioritized normal
: ---
Assigned To: Marc A. Pelletier
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-06-24 14:00 UTC by Tim Landscheidt
Modified: 2013-06-24 14:46 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Tim Landscheidt 2013-06-24 14:00:00 UTC
We fchdir() down on recursion, but don't fchdir() back, so we can't find any files or directories "after" the first directory.  Test case:

| scfc@tools-login:~/tmp/test$ mkdir DIR && touch DIR/SUBFILE TOPFILE && take DIR TOPFILE
| TOPFILE: No such file or directory
| scfc@tools-login:~/tmp/test$
Comment 1 Peter Bena 2013-06-24 14:12:28 UTC
note that new version of take doesn't have this problem:

https://github.com/benapetr/take
Comment 2 Marc A. Pelletier 2013-06-24 14:46:18 UTC
Yup.  Izabug.  (Relative paths were evaluated from a possibly changed cwd depending on whether some of the command line arguments were directories or not).


Fixed by https://gerrit.wikimedia.org/r/#/c/70170/

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links