From 8c31ceeb263e9cdd5ff1e932472975eb6576ccac Mon Sep 17 00:00:00 2001 From: Lars-Peter Clausen Date: Mon, 3 May 2010 13:45:15 +0200 Subject: [PATCH] Fix going a dir up in the filebrowser --- src/filedialog.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/filedialog.cpp b/src/filedialog.cpp index f5b687a..9a98ed3 100644 --- a/src/filedialog.cpp +++ b/src/filedialog.cpp @@ -155,7 +155,7 @@ bool FileDialog::exec() { } break; case FD_ACTION_GOUP: { string::size_type p = path().rfind("/"); - if (p==string::npos || path().substr(0,11)!="/card" || p<4) + if (p==string::npos || path().compare(0, 5, "/card") != 0 || p<4) return false; else setPath( path().substr(0,p) );