From aee9203df68013a911965b4a1a673d1b05b76686 Mon Sep 17 00:00:00 2001 From: "tg(x)" <*@tg-x.net> Date: Wed, 9 Nov 2011 21:38:06 +0100 Subject: [PATCH] resync --- include/psyc/packet.h | 6 +++--- include/psyc/parse.h | 2 +- src/parse.c | 4 ++-- test/test_psyc.c | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/include/psyc/packet.h b/include/psyc/packet.h index e0d5383..3b5caa0 100644 --- a/include/psyc/packet.h +++ b/include/psyc/packet.h @@ -65,9 +65,9 @@ typedef enum typedef enum { - PSYC_STATE_NOOP = 0, - PSYC_STATE_RESET = '=', - PSYC_STATE_SYNC = '?', + PSYC_STATE_NOOP = 0, + PSYC_STATE_RESET = '=', + PSYC_STATE_RESYNC = '?', } PsycStateOp; /** Structure for a modifier. */ diff --git a/include/psyc/parse.h b/include/psyc/parse.h index b290c5f..d0825f4 100644 --- a/include/psyc/parse.h +++ b/include/psyc/parse.h @@ -153,7 +153,7 @@ typedef enum { /// Operator, name & value contains the respective parts. PSYC_PARSE_ROUTING = 2, /// State sync operation. - PSYC_PARSE_STATE_SYNC = 3, + PSYC_PARSE_STATE_RESYNC = 3, /// State reset operation. PSYC_PARSE_STATE_RESET = 4, /// Start of an incomplete entity modifier. diff --git a/src/parse.c b/src/parse.c index 51246c6..1257845 100644 --- a/src/parse.c +++ b/src/parse.c @@ -289,9 +289,9 @@ PsycParseRC psyc_parse (PsycParseState *state, char *oper, *oper = *(state->buffer.data + state->cursor - 1); switch (*oper) { - case PSYC_STATE_SYNC: + case PSYC_STATE_RESYNC: state->contentParsed += 2; - return PSYC_PARSE_STATE_SYNC; + return PSYC_PARSE_STATE_RESYNC; case PSYC_STATE_RESET: state->contentParsed += 2; return PSYC_PARSE_STATE_RESET; diff --git a/test/test_psyc.c b/test/test_psyc.c index ad052ee..fd37d56 100644 --- a/test/test_psyc.c +++ b/test/test_psyc.c @@ -98,7 +98,7 @@ int test_input (int i, char *recvbuf, size_t nbytes) { packet->routing.lines++; break; - case PSYC_PARSE_STATE_SYNC: + case PSYC_PARSE_STATE_RESYNC: case PSYC_PARSE_STATE_RESET: packet->stateop = oper; break;