From bd82c7d364ac9b38b4e6b22cfa9634185d04b836 Mon Sep 17 00:00:00 2001 From: Ian Pedowitz Date: Thu, 18 Jun 2015 07:42:28 -0700 Subject: Renaming bugreport.txt to bugreportFile.getName() Many times to file a bug, its necessary to take several bugreports and attach them all to the same bug. With the current implementation, all extracted files are bugreport.txt which makes it difficult to attach several bugreports to the same bug, and reference them throughout the bug uniquely. Bug: 20447313 Change-Id: I22d2286d06c8dfb82273b5b98c48b21f77941b15 --- packages/Shell/src/com/android/shell/BugreportReceiver.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'packages/Shell') diff --git a/packages/Shell/src/com/android/shell/BugreportReceiver.java b/packages/Shell/src/com/android/shell/BugreportReceiver.java index 13747ed..0005d6e 100644 --- a/packages/Shell/src/com/android/shell/BugreportReceiver.java +++ b/packages/Shell/src/com/android/shell/BugreportReceiver.java @@ -199,7 +199,7 @@ public class BugreportReceiver extends BroadcastReceiver { try (InputStream is = new FileInputStream(bugreportFile); ZipOutputStream zos = new ZipOutputStream( new BufferedOutputStream(new FileOutputStream(bugreportZippedFile)))) { - ZipEntry entry = new ZipEntry("bugreport.txt"); + ZipEntry entry = new ZipEntry(bugreportFile.getName()); zos.putNextEntry(entry); int totalBytes = Streams.copy(is, zos); Log.v(TAG, "size of original bugreport: " + totalBytes + " bytes"); -- cgit v1.1