Skip to content

Commit eafc2dd

Browse files
H. Merijn Brandgitster
authored andcommitted
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 <[email protected]> Helped-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1599999 commit eafc2dd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

perl/Git.pm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1039,7 +1039,7 @@ sub _temp_cache {
10391039
$tmpdir = $self->repo_path();
10401040
}
10411041

1042-
($$temp_fd, $fname) = File::Temp->tempfile(
1042+
($$temp_fd, $fname) = File::Temp::tempfile(
10431043
'Git_XXXXXX', UNLINK => 1, DIR => $tmpdir,
10441044
) or throw Error::Simple("couldn't open new temp file");
10451045

0 commit comments

Comments
 (0)