aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2006-09-30 19:37:25 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2006-09-30 19:37:25 +0000
commit3038ac9c1977c8472fdda2d833a4e4fd5ba6ea94 (patch)
treebf0916588f5f19a2400a6abf02de8de31014f0d4
parent02be0f5350fb3b316e864f0484b8998ccce66fdd (diff)
downloadbusybox-w32-3038ac9c1977c8472fdda2d833a4e4fd5ba6ea94.tar.gz
busybox-w32-3038ac9c1977c8472fdda2d833a4e4fd5ba6ea94.tar.bz2
busybox-w32-3038ac9c1977c8472fdda2d833a4e4fd5ba6ea94.zip
vconfig: fix bug 701 (I be damned if I understand it)
-rw-r--r--archival/libunarchive/decompress_unzip.c12
-rw-r--r--networking/vconfig.c5
2 files changed, 9 insertions, 8 deletions
diff --git a/archival/libunarchive/decompress_unzip.c b/archival/libunarchive/decompress_unzip.c
index 74de9af44..989ac4fd8 100644
--- a/archival/libunarchive/decompress_unzip.c
+++ b/archival/libunarchive/decompress_unzip.c
@@ -806,11 +806,11 @@ static int inflate_get_next_window(void)
806 } 806 }
807 807
808 switch (method) { 808 switch (method) {
809 case -1: ret = inflate_stored(0,0,0,0); 809 case -1: ret = inflate_stored(0,0,0,0);
810 break; 810 break;
811 case -2: ret = inflate_codes(0,0,0,0,0); 811 case -2: ret = inflate_codes(0,0,0,0,0);
812 break; 812 break;
813 default: bb_error_msg_and_die("inflate error %d", method); 813 default: bb_error_msg_and_die("inflate error %d", method);
814 } 814 }
815 815
816 if (ret == 1) { 816 if (ret == 1) {
@@ -911,7 +911,7 @@ int inflate_gunzip(int in, int out)
911 if (gunzip_bytes_out != 911 if (gunzip_bytes_out !=
912 (bytebuffer[bytebuffer_offset] | (bytebuffer[bytebuffer_offset+1] << 8) | 912 (bytebuffer[bytebuffer_offset] | (bytebuffer[bytebuffer_offset+1] << 8) |
913 (bytebuffer[bytebuffer_offset+2] << 16) | (bytebuffer[bytebuffer_offset+3] << 24))) { 913 (bytebuffer[bytebuffer_offset+2] << 16) | (bytebuffer[bytebuffer_offset+3] << 24))) {
914 bb_error_msg("Incorrect length"); 914 bb_error_msg("incorrect length");
915 return -1; 915 return -1;
916 } 916 }
917 917
diff --git a/networking/vconfig.c b/networking/vconfig.c
index 15a611098..6c808eb2f 100644
--- a/networking/vconfig.c
+++ b/networking/vconfig.c
@@ -72,7 +72,7 @@ static const char cmds[] = {
72 's', 'e', 't', '_', 72 's', 'e', 't', '_',
73 'n', 'a', 'm', 'e', '_', 73 'n', 'a', 'm', 'e', '_',
74 't', 'y', 'p', 'e', 0, 74 't', 'y', 'p', 'e', 0,
75 4, SET_VLAN_FLAG_CMD, 12, 75 5, SET_VLAN_FLAG_CMD, 12,
76 's', 'e', 't', '_', 76 's', 'e', 't', '_',
77 'f', 'l', 'a', 'g', 0, 77 'f', 'l', 'a', 'g', 0,
78 5, SET_VLAN_EGRESS_PRIORITY_CMD, 18, 78 5, SET_VLAN_EGRESS_PRIORITY_CMD, 18,
@@ -145,6 +145,8 @@ int vconfig_main(int argc, char **argv)
145 * more of a pain. */ 145 * more of a pain. */
146 if (ifr.cmd == SET_VLAN_FLAG_CMD) { /* set_flag */ 146 if (ifr.cmd == SET_VLAN_FLAG_CMD) { /* set_flag */
147 ifr.u.flag = bb_xgetularg10_bnd(p, 0, 1); 147 ifr.u.flag = bb_xgetularg10_bnd(p, 0, 1);
148 /* DM: in order to set reorder header, qos must be set */
149 ifr.vlan_qos = bb_xgetularg10_bnd(argv[3], 0, 7);
148 } else if (ifr.cmd == ADD_VLAN_CMD) { /* add */ 150 } else if (ifr.cmd == ADD_VLAN_CMD) { /* add */
149 ifr.u.VID = bb_xgetularg10_bnd(p, 0, VLAN_GROUP_ARRAY_LEN-1); 151 ifr.u.VID = bb_xgetularg10_bnd(p, 0, VLAN_GROUP_ARRAY_LEN-1);
150 } else if (ifr.cmd != DEL_VLAN_CMD) { /* set_{egress|ingress}_map */ 152 } else if (ifr.cmd != DEL_VLAN_CMD) { /* set_{egress|ingress}_map */
@@ -160,4 +162,3 @@ int vconfig_main(int argc, char **argv)
160 162
161 return 0; 163 return 0;
162} 164}
163