From: Fredrik Tolf Date: Mon, 10 Nov 2014 21:11:28 +0000 (+0100) Subject: patplex: Fixed segfault bug in pattern replacement. X-Git-Url: http://git.dolda2000.com/gitweb/?a=commitdiff_plain;h=8ea85a4e33fac0e5df05ee0ba96600d0f241ca64;p=ashd.git patplex: Fixed segfault bug in pattern replacement. --- diff --git a/src/patplex.c b/src/patplex.c index d0e2dad..9939543 100644 --- a/src/patplex.c +++ b/src/patplex.c @@ -383,12 +383,14 @@ static void qoffsets(char *buf, int *obuf, char *pstr, int unquote) o++; } buf[o] = 0; + obuf[o] = i; } else { for(i = 0; pstr[i]; i++) { buf[i] = pstr[i]; obuf[i] = i; } buf[i] = 0; + obuf[i] = i; } }