Skip to content

Commit 3da8fbc

Browse files
committed
fix CmdFileDelete (for #4952)
1 parent 2a56298 commit 3da8fbc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/SumatraPDF.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2991,7 +2991,7 @@ static void DeleteCurrentFile(MainWindow* win) {
29912991
return;
29922992
}
29932993
auto* ctrl = win->ctrl;
2994-
const char* path = ctrl->GetFilePath();
2994+
const char* path = str::DupTemp(ctrl->GetFilePath());
29952995
// this happens e.g. for embedded documents and directories
29962996
if (!file::Exists(path)) {
29972997
return;

0 commit comments

Comments
 (0)