From 2276d836398564a90f5ff237e63ca3104ae509f0 Mon Sep 17 00:00:00 2001 From: Eric Andersen Date: Thu, 11 Jul 2002 11:11:56 +0000 Subject: Fixup warnings and undefined operations that show up in gcc-3.1 -Erik --- editors/sed.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'editors') diff --git a/editors/sed.c b/editors/sed.c index 93faf00c2..84aea9b0a 100644 --- a/editors/sed.c +++ b/editors/sed.c @@ -401,8 +401,10 @@ static char *parse_cmd_str(struct sed_cmd * const sed_cmd, const char *const cmd idx = get_address(sed_cmd, cmdstr, &sed_cmd->beg_line, &sed_cmd->beg_match); /* second part (if present) will begin with a comma */ - if (cmdstr[idx] == ',') - idx += get_address(sed_cmd, &cmdstr[++idx], &sed_cmd->end_line, &sed_cmd->end_match); + if (cmdstr[idx] == ',') { + idx++; + idx += get_address(sed_cmd, &cmdstr[idx], &sed_cmd->end_line, &sed_cmd->end_match); + } /* skip whitespace before the command */ while (isspace(cmdstr[idx])) -- cgit v1.2.3