From 5501530a778ad588a8ccd3f1584ea58f74c0cec9 Mon Sep 17 00:00:00 2001 From: etobi Date: Tue, 3 Sep 2013 09:48:52 +0200 Subject: Imported Upstream version 1.1.1+rev1483 --- util/szap/lnb.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'util/szap/lnb.c') diff --git a/util/szap/lnb.c b/util/szap/lnb.c index 9052d1c..3202da1 100644 --- a/util/szap/lnb.c +++ b/util/szap/lnb.c @@ -44,8 +44,7 @@ static struct lnb_types_st lnbs[] = { * Increment curno each time */ -struct lnb_types_st * -lnb_enum(int curno) +struct lnb_types_st *lnb_enum(int curno) { if (curno >= (int) (sizeof(lnbs) / sizeof(lnbs[0]))) return (struct lnb_types_st *)NULL; @@ -57,16 +56,16 @@ lnb_enum(int curno) * otherwise low[,high[,switch]] */ -int -lnb_decode(char *str, struct lnb_types_st *lnbp) +int lnb_decode(char *str, struct lnb_types_st *lnbp) { -int i; -char *cp, *np; + int i; + char *cp, *np; memset(lnbp, 0, sizeof(*lnbp)); cp = str; while(*cp && isspace(*cp)) cp++; + if (isalpha(*cp)) { for (i = 0; i < (int)(sizeof(lnbs) / sizeof(lnbs[0])); i++) { if (!strcasecmp(lnbs[i].name, cp)) { -- cgit v1.2.3