Fix broken opening URLs e.g. when using the 'builtin' Run command.

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@4860 ea778897-0a13-0410-b9d1-a72fbfd435f5
This commit is contained in:
Enrico Tröger 2010-04-25 17:42:56 +00:00
parent 1cac20b8da
commit f12ed2fabe
2 changed files with 6 additions and 2 deletions

View File

@ -6,6 +6,7 @@
* src/win32.c: * src/win32.c:
Change the limit for the command line length when executing commands Change the limit for the command line length when executing commands
to a maximum of 32768 characters (closes #2979697). to a maximum of 32768 characters (closes #2979697).
Fix broken opening URLs e.g. when using the 'builtin' Run command.
* tagmanager/ctags.c: * tagmanager/ctags.c:
Change eFree() to simply ignore NULL pointers instead of asserting. Change eFree() to simply ignore NULL pointers instead of asserting.
* src/main.c: * src/main.c:

View File

@ -700,8 +700,11 @@ void win32_open_browser(const gchar *uri)
if (strncmp(uri, "file://", 7) == 0) if (strncmp(uri, "file://", 7) == 0)
{ {
uri += 7; uri += 7;
while (*uri == '/') if (strchr(uri, ':') != NULL)
uri++; {
while (*uri == '/')
uri++;
}
} }
ShellExecute(NULL, "open", uri, NULL, NULL, SW_SHOWNORMAL); ShellExecute(NULL, "open", uri, NULL, NULL, SW_SHOWNORMAL);
} }