aboutsummaryrefslogtreecommitdiff
path: root/networking/libiproute
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2016-04-21 18:38:51 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2016-04-21 18:38:51 +0200
commit9de2e5a22213842da5b116723392de88de9ed419 (patch)
treedff999a566382174e084d377dc3b4c03de1d4c62 /networking/libiproute
parent47cfbf32fd66563f8c4e09ad6cced6abfbe2fad5 (diff)
downloadbusybox-w32-9de2e5a22213842da5b116723392de88de9ed419.tar.gz
busybox-w32-9de2e5a22213842da5b116723392de88de9ed419.tar.bz2
busybox-w32-9de2e5a22213842da5b116723392de88de9ed419.zip
*: hopefully all setup_common_bufsiz() are in place
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/libiproute')
-rw-r--r--networking/libiproute/ipaddress.c5
-rw-r--r--networking/libiproute/ipneigh.c3
-rw-r--r--networking/libiproute/iproute.c3
3 files changed, 10 insertions, 1 deletions
diff --git a/networking/libiproute/ipaddress.c b/networking/libiproute/ipaddress.c
index 2c0f514c7..d9e099607 100644
--- a/networking/libiproute/ipaddress.c
+++ b/networking/libiproute/ipaddress.c
@@ -41,7 +41,7 @@ struct filter_t {
41typedef struct filter_t filter_t; 41typedef struct filter_t filter_t;
42 42
43#define G_filter (*(filter_t*)bb_common_bufsiz1) 43#define G_filter (*(filter_t*)bb_common_bufsiz1)
44 44#define INIT_G() do { setup_common_bufsiz(); } while (0)
45 45
46static void print_link_flags(unsigned flags, unsigned mdown) 46static void print_link_flags(unsigned flags, unsigned mdown)
47{ 47{
@@ -745,6 +745,9 @@ int FAST_FUNC do_ipaddr(char **argv)
745 /* 0 1 2 3 4 5 6 7 8 */ 745 /* 0 1 2 3 4 5 6 7 8 */
746 "add\0""change\0""chg\0""replace\0""delete\0""list\0""show\0""lst\0""flush\0"; 746 "add\0""change\0""chg\0""replace\0""delete\0""list\0""show\0""lst\0""flush\0";
747 int cmd = 2; 747 int cmd = 2;
748
749 INIT_G();
750
748 if (*argv) { 751 if (*argv) {
749 cmd = index_in_substrings(commands, *argv); 752 cmd = index_in_substrings(commands, *argv);
750 if (cmd < 0) 753 if (cmd < 0)
diff --git a/networking/libiproute/ipneigh.c b/networking/libiproute/ipneigh.c
index 151d3d109..d2028b7b6 100644
--- a/networking/libiproute/ipneigh.c
+++ b/networking/libiproute/ipneigh.c
@@ -42,6 +42,7 @@ struct filter_t {
42typedef struct filter_t filter_t; 42typedef struct filter_t filter_t;
43 43
44#define G_filter (*(filter_t*)bb_common_bufsiz1) 44#define G_filter (*(filter_t*)bb_common_bufsiz1)
45#define INIT_G() do { setup_common_bufsiz(); } while (0)
45 46
46static int flush_update(void) 47static int flush_update(void)
47{ 48{
@@ -339,6 +340,8 @@ int FAST_FUNC do_ipneigh(char **argv)
339 /*0-1*/ "show\0" "flush\0"; 340 /*0-1*/ "show\0" "flush\0";
340 int command_num; 341 int command_num;
341 342
343 INIT_G();
344
342 if (!*argv) 345 if (!*argv)
343 return ipneigh_list_or_flush(argv, 0); 346 return ipneigh_list_or_flush(argv, 0);
344 347
diff --git a/networking/libiproute/iproute.c b/networking/libiproute/iproute.c
index 34d4f4758..e674e9a0d 100644
--- a/networking/libiproute/iproute.c
+++ b/networking/libiproute/iproute.c
@@ -45,6 +45,7 @@ struct filter_t {
45typedef struct filter_t filter_t; 45typedef struct filter_t filter_t;
46 46
47#define G_filter (*(filter_t*)bb_common_bufsiz1) 47#define G_filter (*(filter_t*)bb_common_bufsiz1)
48#define INIT_G() do { setup_common_bufsiz(); } while (0)
48 49
49static int flush_update(void) 50static int flush_update(void)
50{ 51{
@@ -903,6 +904,8 @@ int FAST_FUNC do_iproute(char **argv)
903 unsigned flags = 0; 904 unsigned flags = 0;
904 int cmd = RTM_NEWROUTE; 905 int cmd = RTM_NEWROUTE;
905 906
907 INIT_G();
908
906 if (!*argv) 909 if (!*argv)
907 return iproute_list_or_flush(argv, 0); 910 return iproute_list_or_flush(argv, 0);
908 911