Commit 582f234e authored by Niels Möller's avatar Niels Möller

Deleted useless for loop

parent 6e501242
2014-04-16 Niels Möller <nisse@lysator.liu.se>
* tools/input.c (sexp_get_quoted_char): Deleted useless for loop.
2014-04-13 Niels Möller <nisse@lysator.liu.se> 2014-04-13 Niels Möller <nisse@lysator.liu.se>
* rsa-compat.c: Deleted file. * rsa-compat.c: Deleted file.
......
...@@ -150,41 +150,40 @@ sexp_get_quoted_char(struct sexp_input *input) ...@@ -150,41 +150,40 @@ sexp_get_quoted_char(struct sexp_input *input)
{ {
sexp_next_char(input); sexp_next_char(input);
for (;;) switch (input->c)
switch (input->c) {
{ default:
default: return 1;
return 1; case '\"':
case '\"': return 0;
return 0; case '\\':
case '\\': sexp_next_char(input);
sexp_next_char(input);
switch (input->c) switch (input->c)
{ {
case 'b': input->c = '\b'; return 1; case 'b': input->c = '\b'; return 1;
case 't': input->c = '\t'; return 1; case 't': input->c = '\t'; return 1;
case 'n': input->c = '\n'; return 1; case 'n': input->c = '\n'; return 1;
case 'f': input->c = '\f'; return 1; case 'f': input->c = '\f'; return 1;
case 'r': input->c = '\r'; return 1; case 'r': input->c = '\r'; return 1;
case '\\': input->c = '\\'; return 1; case '\\': input->c = '\\'; return 1;
case 'o': case 'o':
case 'x': case 'x':
/* FIXME: Not implemnted */ /* FIXME: Not implemnted */
abort(); abort();
case '\n': case '\n':
if (sexp_next_char(input) == '\r') if (sexp_next_char(input) == '\r')
sexp_next_char(input); sexp_next_char(input);
break; break;
case '\r': case '\r':
if (sexp_next_char(input) == '\n') if (sexp_next_char(input) == '\n')
sexp_next_char(input); sexp_next_char(input);
break; break;
} }
return 1; return 1;
} }
} }
static void static void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment