X-Git-Url: https://git.sthu.org/?p=pygdb.git;a=blobdiff_plain;f=pygdb.vim;h=b02495ad079d52f81d0ee4a7306047c6d61f1c3a;hp=642b327f7c5d545bc5c1d431d395d88ce1967f50;hb=c827b85fc2293254e20b0e9573f3b95f1472f8af;hpb=7c7da5bcd494d7a53b40952232a889f59c4dfbf2 diff --git a/pygdb.vim b/pygdb.vim index 642b327..b02495a 100644 --- a/pygdb.vim +++ b/pygdb.vim @@ -37,7 +37,15 @@ execsign = None def gdbLaunch(): global gdbBps, clientcmd - clientcmd = vim.eval("input('Client commando: ', '%s')" % clientcmd).strip() + clientcmd = vim.eval("input('Client commando: ', '%s')" % clientcmd) + + #Pressed esq? + if clientcmd == None: + clientcmd = "" + return + + #Strip away white space + clientcmd = clientcmd.strip() if clientcmd.strip()=="": print "No command given!" @@ -205,7 +213,12 @@ def toAbsPath(path): #We need the client command to expand the paths... while clientcmd == "" or not cmdset: - clientcmd = vim.eval("input('Client commando: ', '%s')" % clientcmd).strip() + clientcmd = vim.eval("input('Client commando: ', '%s')" % clientcmd) + + if clientcmd == None: + clientcmd = "" + clientcmd = clientcmd.strip() + cmdset = True #Get the dirs where executeable is in