diff --git a/exec.cpp b/exec.cpp index e72a787f5..1eb91cc81 100644 --- a/exec.cpp +++ b/exec.cpp @@ -1248,7 +1248,7 @@ void exec(parser_t &parser, job_t *j) std::string actual_cmd_str = wcs2string(p->actual_cmd); const char *actual_cmd = actual_cmd_str.c_str(); - const wchar_t *reader_current_filename(); + const wchar_t *reader_current_filename(void); if (g_log_forks) { const wchar_t *file = reader_current_filename(); diff --git a/expand.cpp b/expand.cpp index 860c6dec6..c2095f37e 100644 --- a/expand.cpp +++ b/expand.cpp @@ -753,14 +753,14 @@ static int expand_pid(const wcstring &instr_with_sep, if (wcsncmp(in+1, SELF_STR, wcslen(in+1))==0) { append_completion(out, - SELF_STR+wcslen(in+1), + &SELF_STR[wcslen(in+1)], COMPLETE_SELF_DESC, 0); } else if (wcsncmp(in+1, LAST_STR, wcslen(in+1))==0) { append_completion(out, - LAST_STR+wcslen(in+1), + &LAST_STR[wcslen(in+1)], COMPLETE_LAST_DESC, 0); }