aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2012-11-05 14:18:36 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2012-11-05 14:18:36 +0100
commita803bfa0f06c10d8581bd457b9ba937466c73588 (patch)
treec4a6b83f2d4e847683f169bf8a0e1870df6b4400
parent11181335f9a97feddb30da4d09f9cd3739b8badd (diff)
downloadbusybox-w32-a803bfa0f06c10d8581bd457b9ba937466c73588.tar.gz
busybox-w32-a803bfa0f06c10d8581bd457b9ba937466c73588.tar.bz2
busybox-w32-a803bfa0f06c10d8581bd457b9ba937466c73588.zip
ifupdown: remove unused errno assignments
function old new delta execute 607 571 -36 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--networking/ifupdown.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/networking/ifupdown.c b/networking/ifupdown.c
index 9fc1266da..650cc706f 100644
--- a/networking/ifupdown.c
+++ b/networking/ifupdown.c
@@ -49,9 +49,6 @@
49#include <fnmatch.h> 49#include <fnmatch.h>
50 50
51#define MAX_OPT_DEPTH 10 51#define MAX_OPT_DEPTH 10
52#define EUNBALBRACK 10001
53#define EUNDEFVAR 10002
54#define EUNBALPER 10000
55 52
56#if ENABLE_FEATURE_IFUPDOWN_MAPPING 53#if ENABLE_FEATURE_IFUPDOWN_MAPPING
57#define MAX_INTERFACE_LENGTH 10 54#define MAX_INTERFACE_LENGTH 10
@@ -283,7 +280,7 @@ static char *parse(const char *command, struct interface_defn_t *ifd)
283 command++; 280 command++;
284 nextpercent = strchr(command, '%'); 281 nextpercent = strchr(command, '%');
285 if (!nextpercent) { 282 if (!nextpercent) {
286 errno = EUNBALPER; 283 /* Unterminated %var% */
287 free(result); 284 free(result);
288 return NULL; 285 return NULL;
289 } 286 }
@@ -328,13 +325,13 @@ static char *parse(const char *command, struct interface_defn_t *ifd)
328 } 325 }
329 326
330 if (opt_depth > 1) { 327 if (opt_depth > 1) {
331 errno = EUNBALBRACK; 328 /* Unbalanced bracket */
332 free(result); 329 free(result);
333 return NULL; 330 return NULL;
334 } 331 }
335 332
336 if (!okay[0]) { 333 if (!okay[0]) {
337 errno = EUNDEFVAR; 334 /* Undefined variable and we aren't in a bracket */
338 free(result); 335 free(result);
339 return NULL; 336 return NULL;
340 } 337 }