Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Emits a perl warning about uninitialized value when run from a removed directory #634

Closed
xtaran opened this issue Mar 5, 2017 · 3 comments
Assignees
Labels
Milestone

Comments

@xtaran
Copy link

xtaran commented Mar 5, 2017

Originally reported in Debian against ack 2.15_01, but I can also reproduce this with ack 2.14 as well as ack 2.15_03:

This program emits a perl warning when it is run from a directory that has been removed. To demonstrate:

$ mkdir /tmp/aaa
$ cd /tmp/aaa
$ rmdir /tmp/aaa
$ ack foo
Use of uninitialized value $cwd in pattern match (m//) at /usr/share/perl5/App/Ack/ConfigFinder.pm line 122.
@petdance
Copy link
Collaborator

petdance commented Mar 5, 2017

Interesting. Thanks for reporting.

@petdance petdance self-assigned this Mar 14, 2017
@petdance
Copy link
Collaborator

Apparently this can return undef.

my $cwd = Cwd::getcwd();

@petdance petdance added the bug label Mar 17, 2017
petdance added a commit that referenced this issue Mar 24, 2017
@petdance
Copy link
Collaborator

Fixed. Will be released in 2.17_02.

@petdance petdance added this to the 2.18 milestone Mar 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants