aboutsummaryrefslogtreecommitdiffhomepage
path: root/history.cpp
diff options
context:
space:
mode:
authorGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-11-24 22:57:49 -0800
committerGravatar ridiculousfish <corydoras@ridiculousfish.com>2013-11-24 22:58:39 -0800
commit9f6223311e7ae6a9d6d21e33bf0fa67822da6fb6 (patch)
tree401878fd6bfdb121ec41e977af1defe6a001f6f0 /history.cpp
parent90b78326d393d2490e43491a93d8db4b449b972e (diff)
Large cleanup and refactoring of unescape() function.
Diffstat (limited to 'history.cpp')
-rw-r--r--history.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/history.cpp b/history.cpp
index 2c4fcb08..ff0a0865 100644
--- a/history.cpp
+++ b/history.cpp
@@ -1731,8 +1731,9 @@ void history_t::add_with_file_detection(const wcstring &str)
const wchar_t *token_cstr = tok_last(&tokenizer);
if (token_cstr)
{
- wcstring potential_path = token_cstr;
- if (unescape_string(potential_path, false) && string_could_be_path(potential_path))
+ wcstring potential_path;
+ bool unescaped = unescape_string(token_cstr, &potential_path, UNESCAPE_DEFAULT);
+ if (unescaped && string_could_be_path(potential_path))
{
potential_paths.push_back(potential_path);