diff options
Diffstat (limited to 'winsup/cygwin/regexp/regsub.c')
-rw-r--r-- | winsup/cygwin/regexp/regsub.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/winsup/cygwin/regexp/regsub.c b/winsup/cygwin/regexp/regsub.c index 3983cc58b..e544072c1 100644 --- a/winsup/cygwin/regexp/regsub.c +++ b/winsup/cygwin/regexp/regsub.c @@ -69,11 +69,11 @@ char *dest; no = *src++ - '0'; else no = -1; - if (no < 0) { /* Ordinary character. */ - if (c == '\\' && (*src == '\\' || *src == '&')) - c = *src++; - *dst++ = c; - } else if (prog->startp[no] != NULL && prog->endp[no] != NULL) { + if (no < 0) { /* Ordinary character. */ + if (c == '\\' && (*src == '\\' || *src == '&')) + c = *src++; + *dst++ = c; + } else if (prog->startp[no] != NULL && prog->endp[no] != NULL) { len = prog->endp[no] - prog->startp[no]; (void) strncpy(dst, prog->startp[no], len); dst += len; |