From 019fcbc2e8083d02b3b2ddb4ae40a861027bdbac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kristj=C3=A1n=20Valur=20J=C3=B3nsson?= Date: Fri, 13 Apr 2007 22:20:13 +0000 Subject: Fix potential crash in path manipulation on windows --- PC/getpathp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PC/getpathp.c b/PC/getpathp.c index 729d2e4..e62b936 100644 --- a/PC/getpathp.c +++ b/PC/getpathp.c @@ -650,7 +650,7 @@ calculate_path(void) start of the path in question - even if this is one character before the start of the buffer */ - while (*look != DELIM && look >= module_search_path) + while (look >= module_search_path && *look != DELIM) look--; nchars = lookEnd-look; strncpy(lookBuf, look+1, nchars); -- cgit v0.12