aboutsummaryrefslogtreecommitdiff
path: root/libbb/setup_environment.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* sh: don't overwrite login environment variables if already setRon Yorston2014-12-111-0/+11
| | | | | | Certain environment variables (HOME, LOGNAME, USER, SHELL) are set during early shell startup to emulate what login/su would do on UNIX. If any of these are already set don't overwrite them.
* su: do not change to home dir unless -lPascal Bellard2012-06-121-3/+5
| | | | | Signed-off-by: Pascal Bellard <pascal.bellard@ads-lu.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* libbb/login/su: do not sanitize shell name twiceDenys Vlasenko2011-03-061-0/+3
| | | | | | | | | | | function old new delta setup_environment 191 205 +14 login_main 1002 987 -15 su_main 474 458 -16 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/2 up/down: 14/-31) Total: -17 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* *: s/"/bin/sh"/DEFAULT_SHELL, run_shell() API fix, remove unneeded strdupLadislav Michl2010-06-271-2/+2
| | | | | | | | | | function old new delta run_shell 157 166 +9 su_main 477 470 -7 sulogin_main 515 503 -12 Signed-off-by: Ladislav Michl <Ladislav.Michl@seznam.cz> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* setup_environment(): eliminate one parameterDenys Vlasenko2010-02-261-2/+2
| | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* crontab: use setup_environmentBernhard Reutner-Fischer2010-02-261-4/+3
| | | | | | | | | | function old new delta setup_environment 184 198 +14 .rodata 131770 131747 -23 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 14/-23) Total: -9 bytes Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
* setup_environment: cd $HOME regardless of clear_env value.Denis Vlasenko2008-10-301-7/+7
|
* *: introduce and use FAST_FUNC: regparm on i386, otherwise no-onDenis Vlasenko2008-06-271-1/+1
| | | | | | | text data bss dec hex filename 808035 611 6868 815514 c719a busybox_old 804472 611 6868 811951 c63af busybox_unstripped
* dos2unix: tiny shrinkDenis Vlasenko2008-03-171-4/+4
| | | | | | | | | | | | | | | | | | | | | | login,su: fix setup_environment() so that it works as intended (parameter names were a bit misleading) fdisk: shrink help text: shrink function old new delta login_main 1658 1701 +43 setup_environment 206 203 -3 dos_compatible_flag 4 1 -3 dos2unix_main 383 375 -8 get_boot 1724 1702 -22 fdisk_main 2949 2889 -60 packed_usage 24250 23948 -302 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/6 up/down: 43/-398) Total: -355 bytes text data bss dec hex filename 798768 661 7428 806857 c4fc9 busybox_old 798327 658 7428 806413 c4e0d busybox_unstripped
* setup_environment: code shrinkDenis Vlasenko2007-09-101-13/+12
| | | | | | | | | | | | | | | | | | | | run_shell: mark as NORETURN setup_environment, run_shell: add usage comments login: add FIXME :( function old new delta UNSPEC_print 64 66 +2 sulogin_main 509 506 -3 mkfs_minix_main 3070 3067 -3 login_main 1615 1612 -3 su_main 461 448 -13 setup_environment 261 206 -55 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/5 up/down: 2/-77) Total: -75 bytes text data bss dec hex filename 772578 1051 10724 784353 bf7e1 busybox_old 772502 1051 10724 784277 bf795 busybox_unstripped
* remove nearly-duplicate PATHs in several placesDenis Vlasenko2007-06-121-1/+1
| | | | | | | | | | | | | | function old new delta bb_PATH_root_path - 35 +35 varunset 60 58 -2 arith 2042 2033 -9 bb_default_root_login_path 30 - -30 .rodata 128794 128762 -32 which_main 152 117 -35 defpathvar 40 - -40 ------------------------------------------------------------------------------ (add/remove: 1/2 grow/shrink: 0/4 up/down: 35/-148) Total: -113 bytes
* A few more string duplicates found & eliminatedDenis Vlasenko2007-06-121-6/+1
| | | | | | | | # size busybox_old busybox_unstripped text data bss dec hex filename 679693 2700 15632 698025 aa6a9 busybox_old 679523 2700 15632 697855 aa5ff busybox_unstripped
* login: remove setpgrp call (makes it work from shell prompt again).Denis Vlasenko2007-04-121-11/+4
| | | | | login: sanitize stdio descriptors (we are suid, need to be careful!) shrink login and set_environment by ~100 bytes.
* runit/chpst: "change process state" utilityDenis Vlasenko2006-10-031-27/+20
| | | | It's "nice" on steroids - can set uid/gid, mem/cpu limits etc. +3.5k
* Implement optional syslog logging using ordinaryDenis Vlasenko2006-09-061-4/+1
| | | | | | bb_xx_msg calls, and convert networking/* to it. The rest of bbox will be converted gradually.
* just whitespaceTim Riker2006-01-251-2/+2
|
* Revert Tito's patch to zcip. My bad, David Brownell had objected and I missedRob Landley2005-05-031-1/+1
| | | | | it...
* On Tuesday 19 April 2005 21:10, Tito wrote and today added:Rob Landley2005-05-011-1/+1
| | | | | | | | | | | | | > Hi, > this is a first attempt of size optimization for zcip taking into account all > the hints given so far on the list. > I've applied just the more obvious busyboxifications so maybe it could be > optimized more. BTW: I've ripped out a lot of debug code and changed c++ // comments to /* */ as both were rather confusing for a newbie like me. ;-) Sorry to the author for that. I know that this makes mantaining the code easier, but I'm simple minded....
* Remove trailing whitespace. Update copyright to include 2004.Eric Andersen2004-03-151-2/+2
|
* Vodz, last_patch_86Glenn L McGrath2003-05-261-2/+2
|
* Major coreutils update.Manuel Novoa III2003-03-191-2/+2
|
* Port over the last of the tinylogin appletsEric Andersen2002-06-231-0/+93
-Erik