Git.pm: call tempfile from File::Temp as a regular function
We call File::Temp's "tempfile" function as a class method, but it was never designed to be called this way. Older versions seemed to tolerate it, but as of File::Temp 0.23, it blows up like this: $ git svn fetch 'tempfile' can't be called as a method at .../Git.pm line 1117. Fix it by calling it as a regular function, just inside the File::Temp namespace. Signed-off-by: H. Merijn Brand <h.m.brand@xs4all.nl> Helped-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
H. Merijn Brand committed
Apr 29, 2013 at 01:09 UTC
eafc2dd59f4d28d4a01deb24df588fd7a29990d8
1 file changed
+1
-1
perl/Git.pm
+1
-1
@@ -1039,7 +1039,7 @@ sub _temp_cache {
1039
$tmpdir = $self->repo_path();
1040
}
1041
1042
- ($$temp_fd, $fname) = File::Temp->tempfile(
1042
+ ($$temp_fd, $fname) = File::Temp::tempfile(
1043
'Git_XXXXXX', UNLINK => 1, DIR => $tmpdir,
1044
) or throw Error::Simple("couldn't open new temp file");
1045