Commit e61c9f07 authored by garciay's avatar garciay

Enhance file rename operation to preserve file extension

parent 5bb77c68
......@@ -71,7 +71,7 @@ public class pcapdump implements ILayer {
// Check if the file exist, never remove or scratch files
File file = new File(FileName);
if (file.exists()) {
File newFile = new File(FileName + "_" + System.currentTimeMillis());
File newFile = new File(FileName.replace(".", String.format("_%d.", System.currentTimeMillis())));
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment