Skip to content

Commit

Permalink
Reduce variable scope - doc/makedoc.c
Browse files Browse the repository at this point in the history
  • Loading branch information
fekir authored and flatcap committed Mar 3, 2018
1 parent d019ec4 commit da45ad3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions doc/makedoc.c
Original file line number Diff line number Diff line change
Expand Up @@ -905,7 +905,6 @@ static int handle_docline(char *l, FILE *out, int docstat)
{
bool output_dollar = false;
char *ref = NULL;
char save;

s++;
if (*s == '$')
Expand All @@ -924,7 +923,7 @@ static int handle_docline(char *l, FILE *out, int docstat)
s++;

docstat = commit_buf(buf, &d, out, docstat);
save = *s;
const char save = *s;
*s = '\0';
print_ref(out, output_dollar, ref);
*s = save;
Expand Down

0 comments on commit da45ad3

Please sign in to comment.