diff options
author | Ron Yorston <rmy@pobox.com> | 2022-02-09 09:03:18 +0000 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2022-02-09 09:05:39 +0000 |
commit | 492d0a7492a57fe8f02c766e25960b0ce0d88759 (patch) | |
tree | 4f5764a5c2250c031ea05e9aeacbb40d7971f493 /networking | |
parent | 4734416a21312488a5099a297907783bee4ccc22 (diff) | |
parent | caa9c4f707b661cf398f2c2d66f54f5b0d8adfe2 (diff) | |
download | busybox-w32-492d0a7492a57fe8f02c766e25960b0ce0d88759.tar.gz busybox-w32-492d0a7492a57fe8f02c766e25960b0ce0d88759.tar.bz2 busybox-w32-492d0a7492a57fe8f02c766e25960b0ce0d88759.zip |
Merge busybox into merge
Fix conflicts in reset and ash.
Redefine the new safe_read_key() as a reference to read_key().
Disable SHA256_HWACCEL.
Diffstat (limited to 'networking')
-rw-r--r-- | networking/httpd.c | 3 | ||||
-rw-r--r-- | networking/ifupdown.c | 8 | ||||
-rw-r--r-- | networking/inetd.c | 2 | ||||
-rw-r--r-- | networking/interface.c | 6 | ||||
-rw-r--r-- | networking/libiproute/ipaddress.c | 2 | ||||
-rw-r--r-- | networking/udhcp/common.c | 2 | ||||
-rw-r--r-- | networking/udhcp/d6_dhcpc.c | 2 |
7 files changed, 12 insertions, 13 deletions
diff --git a/networking/httpd.c b/networking/httpd.c index 5f7b3a4dd..59b4a769c 100644 --- a/networking/httpd.c +++ b/networking/httpd.c | |||
@@ -1707,8 +1707,7 @@ static void send_cgi_and_exit( | |||
1707 | script = last_slash; | 1707 | script = last_slash; |
1708 | if (script != url) { /* paranoia */ | 1708 | if (script != url) { /* paranoia */ |
1709 | *script = '\0'; | 1709 | *script = '\0'; |
1710 | if (chdir(url + 1) != 0) { | 1710 | if (chdir_or_warn(url + 1) != 0) { |
1711 | bb_perror_msg("can't change directory to '%s'", url + 1); | ||
1712 | goto error_execing_cgi; | 1711 | goto error_execing_cgi; |
1713 | } | 1712 | } |
1714 | // not needed: *script = '/'; | 1713 | // not needed: *script = '/'; |
diff --git a/networking/ifupdown.c b/networking/ifupdown.c index 737113dd4..6c4ae27f2 100644 --- a/networking/ifupdown.c +++ b/networking/ifupdown.c | |||
@@ -532,7 +532,7 @@ static int FAST_FUNC v4tunnel_down(struct interface_defn_t * ifd, execfn * exec) | |||
532 | } | 532 | } |
533 | # endif | 533 | # endif |
534 | 534 | ||
535 | static const struct method_t methods6[] = { | 535 | static const struct method_t methods6[] ALIGN_PTR = { |
536 | # if ENABLE_FEATURE_IFUPDOWN_IP | 536 | # if ENABLE_FEATURE_IFUPDOWN_IP |
537 | { "v4tunnel" , v4tunnel_up , v4tunnel_down , }, | 537 | { "v4tunnel" , v4tunnel_up , v4tunnel_down , }, |
538 | # endif | 538 | # endif |
@@ -627,7 +627,7 @@ struct dhcp_client_t { | |||
627 | const char *stopcmd; | 627 | const char *stopcmd; |
628 | }; | 628 | }; |
629 | 629 | ||
630 | static const struct dhcp_client_t ext_dhcp_clients[] = { | 630 | static const struct dhcp_client_t ext_dhcp_clients[] ALIGN_PTR = { |
631 | { "dhcpcd", | 631 | { "dhcpcd", |
632 | "dhcpcd[[ -h %hostname%]][[ -i %vendor%]][[ -I %client%]][[ -l %leasetime%]] %iface%", | 632 | "dhcpcd[[ -h %hostname%]][[ -i %vendor%]][[ -I %client%]][[ -l %leasetime%]] %iface%", |
633 | "dhcpcd -k %iface%", | 633 | "dhcpcd -k %iface%", |
@@ -774,7 +774,7 @@ static int FAST_FUNC wvdial_down(struct interface_defn_t *ifd, execfn *exec) | |||
774 | "-p /var/run/wvdial.%iface% -s 2", ifd, exec); | 774 | "-p /var/run/wvdial.%iface% -s 2", ifd, exec); |
775 | } | 775 | } |
776 | 776 | ||
777 | static const struct method_t methods[] = { | 777 | static const struct method_t methods[] ALIGN_PTR = { |
778 | { "manual" , manual_up_down, manual_up_down, }, | 778 | { "manual" , manual_up_down, manual_up_down, }, |
779 | { "wvdial" , wvdial_up , wvdial_down , }, | 779 | { "wvdial" , wvdial_up , wvdial_down , }, |
780 | { "ppp" , ppp_up , ppp_down , }, | 780 | { "ppp" , ppp_up , ppp_down , }, |
@@ -797,7 +797,7 @@ static int FAST_FUNC link_up_down(struct interface_defn_t *ifd UNUSED_PARAM, exe | |||
797 | return 1; | 797 | return 1; |
798 | } | 798 | } |
799 | 799 | ||
800 | static const struct method_t link_methods[] = { | 800 | static const struct method_t link_methods[] ALIGN_PTR = { |
801 | { "none", link_up_down, link_up_down } | 801 | { "none", link_up_down, link_up_down } |
802 | }; | 802 | }; |
803 | 803 | ||
diff --git a/networking/inetd.c b/networking/inetd.c index e71be51c3..fb2fbe323 100644 --- a/networking/inetd.c +++ b/networking/inetd.c | |||
@@ -1538,7 +1538,7 @@ int inetd_main(int argc UNUSED_PARAM, char **argv) | |||
1538 | #if ENABLE_FEATURE_INETD_SUPPORT_BUILTIN_ECHO \ | 1538 | #if ENABLE_FEATURE_INETD_SUPPORT_BUILTIN_ECHO \ |
1539 | || ENABLE_FEATURE_INETD_SUPPORT_BUILTIN_DISCARD | 1539 | || ENABLE_FEATURE_INETD_SUPPORT_BUILTIN_DISCARD |
1540 | # if !BB_MMU | 1540 | # if !BB_MMU |
1541 | static const char *const cat_args[] = { "cat", NULL }; | 1541 | static const char *const cat_args[] ALIGN_PTR = { "cat", NULL }; |
1542 | # endif | 1542 | # endif |
1543 | #endif | 1543 | #endif |
1544 | 1544 | ||
diff --git a/networking/interface.c b/networking/interface.c index ea6a2c8a8..6b6c0944a 100644 --- a/networking/interface.c +++ b/networking/interface.c | |||
@@ -446,13 +446,13 @@ static char *get_name(char name[IFNAMSIZ], char *p) | |||
446 | * %n specifiers (even the size of integers may not match). | 446 | * %n specifiers (even the size of integers may not match). |
447 | */ | 447 | */ |
448 | #if INT_MAX == LONG_MAX | 448 | #if INT_MAX == LONG_MAX |
449 | static const char *const ss_fmt[] = { | 449 | static const char *const ss_fmt[] ALIGN_PTR = { |
450 | "%n%llu%u%u%u%u%n%n%n%llu%u%u%u%u%u", | 450 | "%n%llu%u%u%u%u%n%n%n%llu%u%u%u%u%u", |
451 | "%llu%llu%u%u%u%u%n%n%llu%llu%u%u%u%u%u", | 451 | "%llu%llu%u%u%u%u%n%n%llu%llu%u%u%u%u%u", |
452 | "%llu%llu%u%u%u%u%u%u%llu%llu%u%u%u%u%u%u" | 452 | "%llu%llu%u%u%u%u%u%u%llu%llu%u%u%u%u%u%u" |
453 | }; | 453 | }; |
454 | #else | 454 | #else |
455 | static const char *const ss_fmt[] = { | 455 | static const char *const ss_fmt[] ALIGN_PTR = { |
456 | "%n%llu%lu%lu%lu%lu%n%n%n%llu%lu%lu%lu%lu%lu", | 456 | "%n%llu%lu%lu%lu%lu%n%n%n%llu%lu%lu%lu%lu%lu", |
457 | "%llu%llu%lu%lu%lu%lu%n%n%llu%llu%lu%lu%lu%lu%lu", | 457 | "%llu%llu%lu%lu%lu%lu%n%n%llu%llu%lu%lu%lu%lu%lu", |
458 | "%llu%llu%lu%lu%lu%lu%lu%lu%llu%llu%lu%lu%lu%lu%lu%lu" | 458 | "%llu%llu%lu%lu%lu%lu%lu%lu%llu%llu%lu%lu%lu%lu%lu%lu" |
@@ -731,7 +731,7 @@ static const struct hwtype ib_hwtype = { | |||
731 | #endif | 731 | #endif |
732 | 732 | ||
733 | 733 | ||
734 | static const struct hwtype *const hwtypes[] = { | 734 | static const struct hwtype *const hwtypes[] ALIGN_PTR = { |
735 | &loop_hwtype, | 735 | &loop_hwtype, |
736 | ðer_hwtype, | 736 | ðer_hwtype, |
737 | &ppp_hwtype, | 737 | &ppp_hwtype, |
diff --git a/networking/libiproute/ipaddress.c b/networking/libiproute/ipaddress.c index 17a838411..ecc3848ff 100644 --- a/networking/libiproute/ipaddress.c +++ b/networking/libiproute/ipaddress.c | |||
@@ -58,7 +58,7 @@ typedef struct filter_t filter_t; | |||
58 | 58 | ||
59 | static void print_link_flags(unsigned flags, unsigned mdown) | 59 | static void print_link_flags(unsigned flags, unsigned mdown) |
60 | { | 60 | { |
61 | static const int flag_masks[] = { | 61 | static const int flag_masks[] ALIGN_INT = { |
62 | IFF_LOOPBACK, IFF_BROADCAST, IFF_POINTOPOINT, | 62 | IFF_LOOPBACK, IFF_BROADCAST, IFF_POINTOPOINT, |
63 | IFF_MULTICAST, IFF_NOARP, IFF_UP, IFF_LOWER_UP }; | 63 | IFF_MULTICAST, IFF_NOARP, IFF_UP, IFF_LOWER_UP }; |
64 | static const char flag_labels[] ALIGN1 = | 64 | static const char flag_labels[] ALIGN1 = |
diff --git a/networking/udhcp/common.c b/networking/udhcp/common.c index 8e9b93655..ae818db05 100644 --- a/networking/udhcp/common.c +++ b/networking/udhcp/common.c | |||
@@ -19,7 +19,7 @@ const uint8_t MAC_BCAST_ADDR[6] ALIGN2 = { | |||
19 | * See RFC2132 for more options. | 19 | * See RFC2132 for more options. |
20 | * OPTION_REQ: these options are requested by udhcpc (unless -o). | 20 | * OPTION_REQ: these options are requested by udhcpc (unless -o). |
21 | */ | 21 | */ |
22 | const struct dhcp_optflag dhcp_optflags[] = { | 22 | const struct dhcp_optflag dhcp_optflags[] ALIGN2 = { |
23 | /* flags code */ | 23 | /* flags code */ |
24 | { OPTION_IP | OPTION_REQ, 0x01 }, /* DHCP_SUBNET */ | 24 | { OPTION_IP | OPTION_REQ, 0x01 }, /* DHCP_SUBNET */ |
25 | { OPTION_S32 , 0x02 }, /* DHCP_TIME_OFFSET */ | 25 | { OPTION_S32 , 0x02 }, /* DHCP_TIME_OFFSET */ |
diff --git a/networking/udhcp/d6_dhcpc.c b/networking/udhcp/d6_dhcpc.c index 9d2a8f5d3..9fc690315 100644 --- a/networking/udhcp/d6_dhcpc.c +++ b/networking/udhcp/d6_dhcpc.c | |||
@@ -65,7 +65,7 @@ | |||
65 | 65 | ||
66 | /* "struct client_data_t client_data" is in bb_common_bufsiz1 */ | 66 | /* "struct client_data_t client_data" is in bb_common_bufsiz1 */ |
67 | 67 | ||
68 | static const struct dhcp_optflag d6_optflags[] = { | 68 | static const struct dhcp_optflag d6_optflags[] ALIGN2 = { |
69 | #if ENABLE_FEATURE_UDHCPC6_RFC3646 | 69 | #if ENABLE_FEATURE_UDHCPC6_RFC3646 |
70 | { OPTION_6RD | OPTION_LIST | OPTION_REQ, D6_OPT_DNS_SERVERS }, | 70 | { OPTION_6RD | OPTION_LIST | OPTION_REQ, D6_OPT_DNS_SERVERS }, |
71 | { OPTION_DNS_STRING | OPTION_LIST | OPTION_REQ, D6_OPT_DOMAIN_LIST }, | 71 | { OPTION_DNS_STRING | OPTION_LIST | OPTION_REQ, D6_OPT_DOMAIN_LIST }, |