X-Git-Url: http://www.privoxy.org/gitweb/?p=privoxy.git;a=blobdiff_plain;f=pcrs.c;h=0b746a1df255297a69cd8d101d120332d20d6c52;hp=0553a53e9ac34ed700aab8c0d835cacf58075913;hb=9dae3e9be4e16d17fe8ca8c5cb363e3b7b9896aa;hpb=f67b3326138f428863c21c7738e0c8db87fa6f5c diff --git a/pcrs.c b/pcrs.c index 0553a53e..0b746a1d 100644 --- a/pcrs.c +++ b/pcrs.c @@ -1,4 +1,3 @@ -const char pcrs_rcs[] = "$Id: pcrs.c,v 1.50 2016/05/25 10:50:28 fabiankeil Exp $"; /********************************************************************* * * File : $Source: /cvsroot/ijbswa/current/pcrs.c,v $ @@ -55,8 +54,6 @@ const char pcrs_rcs[] = "$Id: pcrs.c,v 1.50 2016/05/25 10:50:28 fabiankeil Exp $ #include "pcrs.h" -const char pcrs_h_rcs[] = PCRS_H_VERSION; - /* * Internal prototypes */ @@ -241,16 +238,12 @@ extern pcrs_substitute *pcrs_compile_fuzzed_replacement(const char *replacement, static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int trivialflag, int capturecount, int *errptr) { int i, k, l, quoted; - size_t length; char *text; pcrs_substitute *r; -#ifdef FUZZ - static const char *replacement_stack; - static const size_t *length_stack; - static pcrs_substitute *r_stack; - - replacement_stack = replacement; - length_stack = &length; +#ifndef FUZZ + size_t length; +#else + static size_t length; #endif i = k = l = quoted = 0; @@ -272,10 +265,6 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr } memset(r, '\0', sizeof(pcrs_substitute)); -#ifdef FUZZ - r_stack = r; -#endif - length = strlen(replacement); if (NULL == (text = (char *)malloc(length + 1))) @@ -418,7 +407,6 @@ static pcrs_substitute *pcrs_compile_replacement(const char *replacement, int tr goto plainchar; } - assert(l < PCRS_MAX_SUBMATCHES - 1); assert(r->backref[l] < PCRS_MAX_SUBMATCHES + 2); /* Valid and in range? -> record */ if ((0 <= r->backref[l]) &&