Refactor code so that other protocols can be added with minimal duplicate code.

This commit is contained in:
Wilco Baan Hofman 2012-08-01 03:29:01 +02:00
parent 21893ff091
commit 1972b32b60
12 changed files with 428 additions and 248 deletions

4
sia.c
View file

@ -638,7 +638,7 @@ const struct {
const char *sia_code_str(char *code) {
const char *sia_code_str(const char *code) {
uint16_t i;
for (i = 0; sia_codes[i].code != NULL; i++) {
@ -650,7 +650,7 @@ const char *sia_code_str(char *code) {
return NULL;
}
const char *sia_code_desc(char *code) {
const char *sia_code_desc(const char *code) {
uint16_t i;
for (i = 0; sia_codes[i].code != NULL; i++) {