aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp/files.c
AgeCommit message (Collapse)Author
2008-11-06build system: tidying up CONFIG_xxx names (suggested by Rob)Denis Vlasenko
2008-09-26dhcp: add FAST_FUNC as appropriate. -160 bytes.Denis Vlasenko
2008-07-26fix several problems with config parser:Denis Vlasenko
a bug where it underflows the string a bug where it never frees parser_t struct make read_config() return 0 if parser is NULL, make config_close() accept and ignore NULL parser - eliminates many if() blocks reverse the sense of parser bit flags - negative flags are harder to grok. hexdump: revert the change to use config parser, it is BIGGER and also requires additional quirks in parser *: explicitly use PARSER_NORMAL instead of 0 function old new delta login_main 1575 1596 +21 config_close 18 29 +11 bbunpack 383 391 +8 qgravechar 106 109 +3 rtnl_tab_initialize 121 117 -4 expand 1697 1693 -4 man_main 717 712 -5 nameif_main 674 668 -6 hexdump_main 597 591 -6 read_config 217 209 -8 dnsd_main 1478 1470 -8 sysctl_main 203 189 -14 config_open2 44 25 -19 make_device 1177 1141 -36 config_read 597 549 -48 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/11 up/down: 43/-158) Total: -115 bytes
2008-07-21libbb: [x]fopen_for_{read,write} introduced and used.Denis Vlasenko
(by Valdimir) function old new delta config_open2 - 41 +41 config_read 507 542 +35 find_pair 169 187 +18 fopen_for_write - 14 +14 fopen_for_read - 14 +14 find_main 406 418 +12 xfopen_for_write - 10 +10 xfopen_for_read - 10 +10 popstring 134 140 +6 parse_inittab 396 401 +5 next_token 923 928 +5 pack_gzip 1659 1661 +2 bb__parsespent 117 119 +2 fallbackSort 1719 1717 -2 evalvar 1376 1374 -2 qrealloc 36 33 -3 ... ... ... ... singlemount 4579 4569 -10 process_stdin 443 433 -10 patch_main 1111 1101 -10 ifupdown_main 2175 2165 -10 file_action_grep 90 80 -10 uuidcache_init 649 637 -12 hush_main 797 785 -12 read_config 230 217 -13 dpkg_main 3835 3820 -15 read_line_input 3134 3110 -24 sysctl_main 232 203 -29 config_open 40 10 -30 WARN_BAD_LINE 44 - -44 login_main 1714 1575 -139 ------------------------------------------------------------------------------ (add/remove: 5/1 grow/shrink: 8/74 up/down: 174/-737) Total: -563 bytes
2008-07-20udhcp: use libbb for config file parsing (by Vladimir)Denis Vlasenko
function old new delta read_config 313 230 -83
2008-07-05*: rename ATTRIBUTE_XXX to just XXX.Denis Vlasenko
2008-05-15more of -Wall fixes from Cristian Ionescu-Idbohrn.Denis Vlasenko
Some are fixing real bugs. function old new delta syslogd_main 938 958 +20 get_signum 136 143 +7 obj_load 777 782 +5 recv_from_to 210 214 +4 get_next_block 1795 1799 +4 display_topmem_process_list 1117 1121 +4 logread_main 484 487 +3 buffer_fill_and_print 73 76 +3 kill_main 687 689 +2 ll_remember_index 240 241 +1 do_stats 452 453 +1 if_readconf 166 165 -1 display_process_list 1192 1191 -1 run_applet_and_exit 507 505 -2 print_signames 33 31 -2 parse_one_line 1092 1090 -2 find_out_spec 57 55 -2 add_ksymoops_symbols 421 419 -2 ash_main 1407 1402 -5 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 11/8 up/down: 54/-17) Total: 37 bytes
2008-05-12-Wall fixes by Cristian Ionescu-Idbohrn. No object code changes.Denis Vlasenko
2008-04-10udhcp,ipcalc: simple code shrink (Nico Erfurth <masta AT perlgolf.de>)Denis Vlasenko
function old new delta ipcalc_main 609 610 +1 read_staticlease 102 85 -17 ether_aton 17 - -17
2008-04-02udhcpc: add -o "do not request options by default" switchDenis Vlasenko
(by L. Gabriel Somlo <somlo AT cmu.edu>) function old new delta udhcpc_main 2513 2554 +41 static.udhcpc_longopts 226 247 +21 add_param_req_option 119 132 +13 packed_usage 23952 23964 +12 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 4/0 up/down: 87/0) Total: 87 bytes
2008-03-20udhcp: fix wrong order of args here: index_in_strings(opt, dhcp_option_strings);Denis Vlasenko
code shrink while at it: function old new delta read_config 406 323 -83
2008-03-17*: shrink by using [f]open_or_warn_stdin where appropriateDenis Vlasenko
function old new delta lsattr_main 62 143 +81 open_or_warn_stdin - 36 +36 fclose_if_not_stdin 20 47 +27 xfopen_stdin - 20 +20 tac_main 336 356 +20 cksum_main 249 259 +10 bb_argv_dash - 8 +8 su_main 448 455 +7 cmp_main 630 633 +3 passwd_main 1072 1074 +2 uudecode_main 317 315 -2 text_yank 110 108 -2 handle_incoming_and_exit 2653 2651 -2 flags 5 1 -4 write_leases 235 230 -5 fopen_or_warn_stdin 48 42 -6 fold_main 648 642 -6 static.argv_dash 8 - -8 sum_main 142 128 -14 tail_main 1237 1221 -16 sed_main 711 695 -16 cmp_xfopen_input 17 - -17 bb_cat 113 96 -17 catv_main 328 306 -22 strings_main 457 434 -23 hash_file 298 274 -24 sum_file 353 325 -28 sort_main 904 859 -45 expand_main 736 686 -50 cut_main 1116 1065 -51 md5_sha1_sum_main 549 493 -56 lsattr_args 90 - -90 read_stduu 408 255 -153 ------------------------------------------------------------------------------ (add/remove: 3/3 grow/shrink: 7/20 up/down: 214/-657) Total: -443 bytes text data bss dec hex filename 797417 658 7428 805503 c4a7f busybox_old 796973 658 7428 805059 c48c3 busybox_unstripped
2008-01-29- be C99 friendly. Anonymous unions are a GNU extension. This change isBernhard Reutner-Fischer
size-neutral WRT -std=gnu99 and fixes several compilation errors for strict C99 mode.
2007-12-26save a bit of code with *strchrnul = '\0' trickDenis Vlasenko
function old new delta nextline 59 55 -4 include_conf 902 898 -4 read_config 414 406 -8 fsck_main 1880 1869 -11
2007-11-29dhcp: heed TODO item - divorced options from their string descriptionsDenis Vlasenko
code shrink while at it. function old new delta dhcp_option_strings - 258 +258 udhcp_run_script 1135 1174 +39 dhcp_option_lengths - 11 +11 udhcp_add_simple_option 93 92 -1 packet_num 4 - -4 read_opt 746 739 -7 udhcp_option_lengths 11 - -11 udhcpc_main 2590 2494 -96 dhcp_options 490 70 -420 ------------------------------------------------------------------------------ (add/remove: 2/2 grow/shrink: 1/4 up/down: 308/-539) Total: -231 bytes text data bss dec hex filename 775309 929 9100 785338 bfbba busybox_old 775098 929 9084 785111 bfad7 busybox_unstripped
2007-11-28dhcpc: let server know we don't like oversized packets.Denis Vlasenko
add TODO comment
2007-11-06telnet: use poll, it's shorterDenis Vlasenko
*: style fixes
2007-07-03udhcp: many small fixes:Denis Vlasenko
* arpping(): smaller and even probably fixed * lots of variables/params converted: ulong -> uint32_t * uptime() nuked in favor of monotonic_sec() * udhcp_get_packet(): only one "bad vendor", simplify function old new delta reservedIp 36 35 -1 udhcpc_main 2462 2460 -2 addStaticLease 64 62 -2 static.broken_vendors 16 - -16 uptime 19 - -19 udhcpd_main 1273 1238 -35 udhcp_get_packet 223 184 -39 .rodata 144162 144106 -56 arpping 690 609 -81 ------------------------------------------------------------------------------ (add/remove: 0/2 grow/shrink: 0/7 up/down: 0/-251) Total: -251 bytes text data bss dec hex filename 734241 3028 14400 751669 b7835 busybox_old 734005 3028 14400 751433 b7749 busybox_unstripped
2007-07-01udhcp: new config option "Rewrite the lease file at every new acknowledge"Denis Vlasenko
(Mats Erik Andersson <mats@blue2net.com> (Blue2Net AB)) udhcp: consistently treat server_config.start/end IPs as host-order fix IP parsing for 64bit machines fix unsafe hton macro usage in read_opt() do not chdir("/") when daemonizing fix help text
2007-04-11bb_full_fd_action: remove potential xmalloc from NOFORK pathDenis Vlasenko
cat: stop using stdio.h opens libbb: introduce & use open[3]_or_warn function old new delta open3_or_warn - 54 +54 bb_cat 115 144 +29 open_or_warn - 25 +25 unlzma 2404 2412 +8 chattr_main 334 339 +5 xstrtoul_range_sfx 251 255 +4 telnet_main 1514 1510 -4 static.opt 4 - -4 qgravechar 122 118 -4 fuser_add_pid 61 54 -7 fuser_add_inode 154 147 -7 writeFileToTarball 1542 1534 -8 refresh 1156 1148 -8 do_show 856 846 -10 read_leases 212 200 -12 setup_redirects 236 222 -14 iproute_list_or_flush 1582 1568 -14 read_config 427 411 -16 write_leases 284 264 -20 hash_file 338 318 -20 copy_file 1760 1740 -20 do_iproute 2610 2588 -22 bb_full_fd_action 320 269 -51 open_to_or_warn 103 49 -54 fuser_main 1660 1596 -64 .rodata 131160 131096 -64 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 4/19 up/down: 125/-423) Total: -298 bytes
2007-02-27udhcp: optionally support RFC3397 (by Gabriel L. Somlo <somlo@cmu.edu>)Denis Vlasenko
2007-02-04udhcp: use improved gethostbyname replacement from IPv6 codeDenis Vlasenko
2007-02-02add a comment so that people won't get confusedDenis Vlasenko
2007-02-02udhcpd: allow "domain" to be a list of DNS servers, not just oneDenis Vlasenko
2007-01-19strdup -> xstrdupDenis Vlasenko
sed: de-obfuscate piece of code
2006-11-27safe_strtoXX interface proved to be a bit unconvenient.Denis Vlasenko
Remove it, introduce saner bb_strtoXX. Saved ~350 bytes.
2006-11-23add "wpad" DHCP option. Spotted some optimization opportunities: -80 bytesDenis Vlasenko
2006-11-18small fixes: using fd-based io instead of FILE*-based,Denis Vlasenko
missed O_TRUNC, etc
2006-11-18udhcp: fix indentation and style.Denis Vlasenko
Eliminate (group) a lot of smallish *.h files Remove lots of unneeded #includes
2006-10-20message string changes, mostly for consistency, also -32 bytes in .rodataDenis Vlasenko
2006-10-08attempt to regularize atoi mess.Denis Vlasenko
2006-09-06Implement optional syslog logging using ordinaryDenis Vlasenko
bb_xx_msg calls, and convert networking/* to it. The rest of bbox will be converted gradually.
2006-07-02Standardize on the vi editing directives being on the first line."Robert P. J. Day"
2006-05-28My first bout of untangling udhcp. Make lots of gratuitous #defines goRob Landley
away, substitutie BB_VER for an external VERSION, use busybox CONFIG symbols rather than checking for them then defining others, etc. Lots more cleanup to do...
2006-05-08add back in udhcp supportMike Frysinger
2006-03-23remove in place of external linkMike Frysinger
2006-03-23sync busybox and udhcp treesMike Frysinger
2006-03-01Cleanup patch from Denis Vlasenko. Mostly variants of removing the if(x)Rob Landley
from before "if(x) free(x)".
2006-01-25just whitespaceTim Riker
2005-09-23remove 1 exported"Vladimir N. Oleynik"
2005-09-22move a couple of functions from common code (options.c) to udhcpd privatePaul Fox
code (files.c) to make udhcpc a little smaller.
2004-10-08Wade Berrier writes:Eric Andersen
Hello, Here's a patch for a first attempt at static leases for udhcpd. Included in the tarball are 2 files (static_leases.c, static_leases.h) and a patch against the latest cvs. In the config file you can configure static leases with the following format: static_lease 00:60:08:11:CE:4E 192.168.0.54 static_lease 00:60:08:11:CE:3E 192.168.0.44 Comments/suggestions/improvements are welcome. Wade
2004-03-15Remove trailing whitespace. Update copyright to include 2004.Eric Andersen
2004-01-30Use standard C99 typesEric Andersen
2003-12-18Finish remerging busybox udhcp and udhcp. Some cleanups as well.Russ Dill
2003-12-16clean up some bad, bad formattingRuss Dill
2003-12-16remove reference to missing header file which is breaking the buildEric Andersen
2003-12-16why the complication of a static string rather than a define? gcc isn't dumbRuss Dill
2003-12-16when compiled standalone, udhcp needs these headersRuss Dill
2003-12-16whoopsRuss Dill