Skip to content

Commit

Permalink
Do not manually remove temporary files on Unix in get_command()
Browse files Browse the repository at this point in the history
  • Loading branch information
radarhere committed Feb 13, 2022
1 parent 3ba9587 commit 993bb23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/PIL/ImageShow.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ class UnixViewer(Viewer):

def get_command(self, file, **options):
command = self.get_command_ex(file, **options)[0]
return f"({command} {quote(file)}; rm -f {quote(file)})&"
return f"({command} {quote(file)}"

This comment has been minimized.

Copy link
@newx666

newx666 Apr 17, 2024

You forgot to remove the starting bracket!

- return f"({command} {quote(file)}"
+ return f"{command} {quote(file)}"

Please fix it πŸ™
I could create a PR with the fix, but it's too small change :)

This comment has been minimized.

Copy link
@radarhere

radarhere Apr 17, 2024

Author Member

I've created #7987

This comment has been minimized.

Copy link
@newx666

newx666 Apr 17, 2024

Thanks πŸ‘



class XDGViewer(UnixViewer):
Expand Down

0 comments on commit 993bb23

Please sign in to comment.