return error("Terminal is dumb, but EDITOR unset");
 
        if (strcmp(editor, ":")) {
-               const char *args[] = { editor, path, NULL };
-               struct child_process p;
+               const char *args[] = { editor, real_path(path), NULL };
+               struct child_process p = CHILD_PROCESS_INIT;
                int ret, sig;
 
-               memset(&p, 0, sizeof(p));
                p.argv = args;
                p.env = env;
                p.use_shell = 1;