From 7d6a31954ef4821be4581a356332603f79310980 Mon Sep 17 00:00:00 2001 From: "zhou.yun" Date: Thu, 25 Apr 2024 19:25:39 +0800 Subject: [PATCH] =?UTF-8?q?=E7=BB=99heapdump=E6=96=87=E4=BB=B6=E5=90=8D?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=88=86=E9=9A=94=E7=AC=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../taobao/arthas/core/command/monitor200/HeapDumpCommand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/src/main/java/com/taobao/arthas/core/command/monitor200/HeapDumpCommand.java b/core/src/main/java/com/taobao/arthas/core/command/monitor200/HeapDumpCommand.java index acce76fe4..3e02ef013 100644 --- a/core/src/main/java/com/taobao/arthas/core/command/monitor200/HeapDumpCommand.java +++ b/core/src/main/java/com/taobao/arthas/core/command/monitor200/HeapDumpCommand.java @@ -51,7 +51,7 @@ public class HeapDumpCommand extends AnnotatedCommand { @Override public void process(CommandProcess process) { try { - String dumpFile = file == null ? (process.getArthasOutput().getAbsolutePath()+"heapdump"+System.currentTimeMillis()+".hprof") : null; + String dumpFile = file == null ? (process.getArthasOutput().getAbsolutePath()+File.separator+"heapdump-"+System.currentTimeMillis()+".hprof") : null; if (dumpFile == null || dumpFile.isEmpty()) { String date = new SimpleDateFormat("yyyy-MM-dd-HH-mm").format(new Date()); File file = File.createTempFile("heapdump" + date + (live ? "-live" : ""), ".hprof");