From d11602b916145104f5f5ac58e30641d9591a5856 Mon Sep 17 00:00:00 2001 From: michael Date: Fri, 2 Jan 2015 21:20:17 +0000 Subject: [PATCH] - scan.c, scan.h: remove FORMATTYPE_STRING. It's default since we don't support anything else. git-svn-id: svn://svn.ircd-hybrid.org/svnroot/hopm/branches/1.0.x@5282 82007160-df01-0410-b94d-b575c5fd34c7 --- src/scan.c | 17 +++++------------ src/scan.h | 3 --- 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/src/scan.c b/src/scan.c index f8513c3..be7f28a 100644 --- a/src/scan.c +++ b/src/scan.c @@ -791,11 +791,11 @@ scan_irckline(struct scan_struct *ss, const char *format, const char *type) unsigned int i; struct kline_format_assoc table[] = { - {'i', NULL, FORMATTYPE_STRING }, - {'h', NULL, FORMATTYPE_STRING }, - {'u', NULL, FORMATTYPE_STRING }, - {'n', NULL, FORMATTYPE_STRING }, - {'t', NULL, FORMATTYPE_STRING } + {'i', NULL }, + {'h', NULL }, + {'u', NULL }, + {'n', NULL }, + {'t', NULL } }; table[0].data = ss->ip; @@ -831,10 +831,6 @@ scan_irckline(struct scan_struct *ss, const char *format, const char *type) { if(table[i].key == format[pos + 1]) { - switch(table[i].type) - { - case FORMATTYPE_STRING: - size = strlen(table[i].data); /* Check if the new string can fit! */ @@ -846,9 +842,6 @@ scan_irckline(struct scan_struct *ss, const char *format, const char *type) len += size; } - default: - break; - } } } /* Skip key character */ diff --git a/src/scan.h b/src/scan.h index 8fb3a46..1306359 100644 --- a/src/scan.h +++ b/src/scan.h @@ -47,9 +47,6 @@ struct kline_format_assoc { char key; const void *data; - int type; }; -#define FORMATTYPE_STRING 1 - #endif /* SCAN_H */ -- 2.30.2