Commit Graph

21 Commits

Author SHA1 Message Date
Evan Gates 84b08427a1 remove agetline 2014-11-18 21:05:28 +00:00
FRIGN 7fc5856e64 Tweak NULL-pointer checks
Use !p and p when comparing pointers as opposed to explicit
checks against NULL.  This is generally easier to read.
2014-11-14 10:54:30 +00:00
FRIGN 7d2683ddf2 Sort includes and more cleanup and fixes in util/ 2014-11-14 10:54:10 +00:00
FRIGN eee98ed3a4 Fix coding style
It was about damn time. Consistency is very important in such a
big codebase.
2014-11-13 18:08:43 +00:00
sin 0c5b7b9155 Stop using EXIT_{SUCCESS,FAILURE} 2014-10-02 23:46:59 +01:00
Hiltjo Posthuma fab4b384e7 use agetline instead of agets
also use agetline where fgets with a static buffer was used previously.

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
2014-06-01 18:03:10 +01:00
Hiltjo Posthuma daad071b31 cut, uudecode: free buf after use
Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
2014-06-01 18:01:31 +01:00
Hiltjo Posthuma bd99b92e91 parsemode: rework
- for octal input: reset mode to 0.
- take umask into account.
- make '=rwx' etc work.
- we wont support crazy but valid modes like "a+rw,g=x,o=g"
- uudecode: use parsemode, mask is 0.

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
2014-04-24 11:51:33 +01:00
Hiltjo Posthuma 560340341f make parsemode() generic
use for uudecode and chmod

Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
2014-04-09 15:40:32 +01:00
Hiltjo Posthuma f7403ce6c6 style: whitespace fixes
Signed-off-by: Hiltjo Posthuma <hiltjo@codemadness.org>
2014-04-01 16:20:43 +01:00
sin b0e4b45e3b No need to use do { } while (0) construct 2014-02-04 16:51:34 +00:00
sin 136f2f3b60 Correct error message in uudecode(1) 2014-02-04 15:20:41 +00:00
sin 71461978f2 Error out on invalid mode in uudecode(1) 2014-02-04 15:19:23 +00:00
sin df035a6a2c Break out fclose() 2014-02-04 15:16:16 +00:00
sin 6da5fb7153 Rename check*() to parse*() to be consistent with the rest of sbase 2014-02-04 15:08:08 +00:00
sin d7383490dc Use chmod() directly 2014-02-04 15:08:02 +00:00
sin bf2b270946 A couple more stylistic changes to uudecode(1) 2014-02-04 14:46:34 +00:00
sin ed9985205b Explicitly check for '\0' at the start and exit early 2014-02-04 14:38:43 +00:00
sin c2db1b9ec6 Remember to fclose(nfp) as well 2014-02-04 14:35:13 +00:00
sin 4d8c3d4dc2 Simplify uudecode(1) and fix some bugs 2014-02-04 14:32:36 +00:00
dsp 7008d751b2 Initial commit of the uudecode tool and man page
Currently it operates only on regular files and does not
support Base64.
2014-02-02 20:50:31 +00:00