X-Git-Url: https://git.nmode.ca/signal-cli/blobdiff_plain/0624d6a808b8b2a247aadd96450319bc94e3729f..6bd857ad8bf51bdb207bcdaf6ce058c8311f030e:/src/main/java/org/asamk/signal/manager/util/IOUtils.java diff --git a/src/main/java/org/asamk/signal/manager/util/IOUtils.java b/src/main/java/org/asamk/signal/manager/util/IOUtils.java index 06f8aa22..c0918ae7 100644 --- a/src/main/java/org/asamk/signal/manager/util/IOUtils.java +++ b/src/main/java/org/asamk/signal/manager/util/IOUtils.java @@ -22,7 +22,9 @@ import static java.nio.file.attribute.PosixFilePermission.OWNER_WRITE; public class IOUtils { public static File createTempFile() throws IOException { - return File.createTempFile("signal_tmp_", ".tmp"); + final File tempFile = File.createTempFile("signal-cli_tmp_", ".tmp"); + tempFile.deleteOnExit(); + return tempFile; } public static byte[] readFully(InputStream in) throws IOException {