Index: gdb/cli/cli-cmds.c
--- gdb/cli/cli-cmds.c.orig
+++ gdb/cli/cli-cmds.c
@@ -1060,7 +1060,7 @@ edit_command (const char *arg, int from_tty)
     }
 
   if ((editor = getenv ("EDITOR")) == NULL)
-    editor = "/bin/ex";
+    editor = "/usr/bin/ex";
 
   fn = symtab_to_fullname (sal.symtab);
 
