aboutsummaryrefslogtreecommitdiff
path: root/usr.bin
Commit message (Collapse)AuthorAgeFilesLines
* Welcome unzip(1), a pure BSD drop-in replacement for ports/unzip. In itsDag-Erling Smørgrav2008-01-083-0/+920
| | | | | | | | | | | | | | | current state, it can handle all but four of the 991 zip files (including jar files) I was able to identify in the ports tree. The remaining four are two self-extracting archives and two which have garbage preceding the first local header. This limitation is a feature of libarchive(3) which I am currently working to resolve. The code is unnecessarily large due to the need to emulate the exact command-line syntax and behaviour of ports/unzip. My initial incompatible implementation was one quarter the size of the one I am committing here. Notes: svn path=/head/; revision=175154
* Only use sockoptname() to parse socket option names for SOL_SOCKETJohn Baldwin2008-01-071-4/+6
| | | | | | | | | | requests. MFC after: 3 days Reported by: Michiel Boland michiel boland.org Notes: svn path=/head/; revision=175138
* Make a few messages more consistant with the others.David E. O'Brien2008-01-041-2/+2
| | | | Notes: svn path=/head/; revision=175077
* more style(9)David E. O'Brien2008-01-041-69/+70
| | | | Notes: svn path=/head/; revision=175076
* The break() system call takes a pointer argument, not an integer. ThisJason Evans2008-01-031-1/+1
| | | | | | | change fixes output for break() on LP64 systems. Notes: svn path=/head/; revision=175062
* style(9)David E. O'Brien2008-01-0218-255/+250
| | | | | | | | | | + kread is not a boolean, so check it as such + fix $FreeBSD$ Ids + denote copyrights with /*- + misc whitespace changes. Notes: svn path=/head/; revision=175061
* Remove the old bsdtar test scripts; something muchTim Kientzle2008-01-028-859/+0
| | | | | | | better is almost ready to commit. Notes: svn path=/head/; revision=175052
* A couple of miscellaneous fixes:Tim Kientzle2008-01-023-4/+18
| | | | | | | | | | | * prototypes for optarg/optind on platforms that don't already have them * Disambiguate version number macros * Remove unnecessary PACKAGE_NAME macro * Hook for forthcoming bsdtar test suite * Sync version number up with the portable distribution Notes: svn path=/head/; revision=175051
* Fill in the approximate date when tar(1) first appeared.Tim Kientzle2008-01-021-1/+1
| | | | Notes: svn path=/head/; revision=175050
* Include a suitable stub definition of __FBSDID() for non-FreeBSD platforms.Tim Kientzle2008-01-021-1/+2
| | | | Notes: svn path=/head/; revision=175049
* Use archive_entry_strmode() instead of a local bsdtar_strmode().Tim Kientzle2008-01-023-53/+3
| | | | | | | | | (This does a couple of things that the standard library's strmode() doesn't; it proved useful in bsdcpio as well, so I pushed it down into libarchive.) Notes: svn path=/head/; revision=175048
* Include Guido's copyright for the fnmatch() code I cribbed from.Tim Kientzle2008-01-021-1/+36
| | | | | | | (It's in the C source, just wasn't in the COPYING file until now.) Notes: svn path=/head/; revision=175047
* Add my birthday to the calendar.Weongyo Jeong2008-01-011-0/+1
| | | | | | | Approved by: thompsa (mentor) Notes: svn path=/head/; revision=175040
* follow style(9) more closely and list sys/types.h first after sys/defs.h.Warner Losh2008-01-012-2/+2
| | | | | | | Submitted by: max@ Notes: svn path=/head/; revision=175038
* style(9)Greg Lehey2007-12-301-1/+1
| | | | Notes: svn path=/head/; revision=175003
* If we can't open a calendar file, don't guess why. Check the errorGreg Lehey2007-12-301-1/+2
| | | | | | | | | | return and print a useful message. Prior to this commit, access problems could give rise to messages that the file didn't exist. Notes: svn path=/head/; revision=175002
* Some systems need the types defined in sys/types.h, but lack theWarner Losh2007-12-292-0/+2
| | | | | | | | | sys/types.h polution that FreeBSD has in one of its include files. Since this is a bootstrap tool, include more than is strictly necessary for FreeBSD. Notes: svn path=/head/; revision=174965
* List all environment variables supported by libfetch, along with a referenceDag-Erling Smørgrav2007-12-281-9/+19
| | | | | | | | | to the fetch(3) man page. MFC after: 1 week Notes: svn path=/head/; revision=174960
* Add the ability to clean up all shared memory segments which areEdwin Groothuis2007-12-257-214/+468
| | | | | | | | | | | | | | | | | | | | | | | | unused in one go. From the original PR: I've observed that linux apps running under the linuxulator have a habit of leaving behind shared memory segments which are unused, but which eventually cause the system to run out of free segments and these apps will stop working. ipcrm(1) currently only allows removal of unused message queues, shared memory segments and semaphores on an individual basis, or those having a matching (non-zero) key. However it would often be convenient to just do a complete cleanup of everything, usually as root. PR: bin/118292 Submitted by: Callum Gibson <callumgibson@optusnet.com.au> Not reviewed by: grog@ Approved by: grog@ Notes: svn path=/head/; revision=174891
* usbhidctl appears to not report features and write size correctlyWarner Losh2007-12-211-4/+4
| | | | | | | | | | | This turns out to be due to an argument botch for hid_report_size. The PR contained patches to fix the argument botch. Submitted by: Maurice Castro PR: usb/118915 Notes: svn path=/head/; revision=174826
* Fix disorder introduced in previous commit.Ruslan Ermilov2007-12-201-1/+1
| | | | Notes: svn path=/head/; revision=174814
* Pull ministat into the installed system and write it a man-page.Poul-Henning Kamp2007-12-203-1/+131
| | | | | | | (Repocopied from src/tools/tools/ministat) Notes: svn path=/head/; revision=174810
* Fix printing of the number of syncache entries added.Ruslan Ermilov2007-12-181-2/+2
| | | | Notes: svn path=/head/; revision=174754
* Stylify ipcs/ipcs.c and ipcrm/ipcrm in preparation of the upcomingEdwin Groothuis2007-12-182-375/+461
| | | | | | | | | | | | changes as proposed in bin/118292. Feel free to mention any I have missed, there is much to learn with regarding to style(9). Approved by: grog@ Notes: svn path=/head/; revision=174750
* o Fix a holiday to reflect a reality.Maxim Konovalov2007-12-171-1/+1
| | | | | | | | Submitted by: Andrey V. Elsukov MFC after: 1 week Notes: svn path=/head/; revision=174702
* Give a better description when a install of multiple files failsEdwin Groothuis2007-12-141-1/+6
| | | | | | | | | | | | | because of the absence of a destination directory or if the "destination directory" is not a directory. PR: bin/11826 Submitted by: Denis Eremenko <moonshade@pnhz.kz> Approved by: grog@ X-MFC after: various freezes Notes: svn path=/head/; revision=174587
* Add the -H, -h and -P flags to vmstat. -P causes per-cpu output ofPeter Wemm2007-12-133-20/+207
| | | | | | | | | user/system/idle stats. -h feeds the memory column through humanize_number() to reduce the amount of column overflowing. -H turns this off. -h is turned on by default if stdout is a tty. Notes: svn path=/head/; revision=174573
* Add 'COMM' column to a few more output modes of procstat(1). The onlyRobert Watson2007-12-104-20/+29
| | | | | | | | one it's missing from is the VM display, where there's really not room, and the file output display is looking quite cramped. Notes: svn path=/head/; revision=174530
* Use a clever definition of __FBSDID to allow building on !FreeBSD systems.Warner Losh2007-12-091-2/+5
| | | | Notes: svn path=/head/; revision=174480
* Add several missing comma's in the fancy syscall parsing case beforeJohn Baldwin2007-12-061-0/+12
| | | | | | | | | some arguments that are parsed (e.g., semctl command names). MFC after: 3 days Notes: svn path=/head/; revision=174346
* Display per-thread command line in TDNAME field for -k and -t; ifRobert Watson2007-12-032-21/+71
| | | | | | | | | | | | no per-thread name is available or the name is identical to the process name, display "-" instead. Very slightly shrink the COMM entry to make a bit more room, although this doesn't help with stack traces much. Suggested by: thompsa Notes: svn path=/head/; revision=174230
* Connect procstat(1) to the build.Robert Watson2007-12-021-0/+1
| | | | Notes: svn path=/head/; revision=174200
* Add procstat(1), a process inspection utility. This provides both someRobert Watson2007-12-0212-0/+1459
| | | | | | | | | | | | | | | | | | | | | | of the missing functionality from procfs(4) and new functionality for monitoring and debugging specific processes. procstat(1) operates in the following modes: -b Display binary information for the process. -c Display command line arguments for the process. -f Display file descriptor information for the process. -k Display the stacks of kernel threads in the process. -s Display security credential information for the process. -t Display thread information for the process. -v Display virtual memory mappings for the process. Further revision and modes are expected. Testing, ideas, etc: cognet, sam, Skip Ford <skip at menantico dot com> Wesley Shields <wxs at atarininja dot org> Notes: svn path=/head/; revision=174199
* Add a cross-reference to newgrp(1).Philip Paeps2007-11-301-0/+1
| | | | | | | | | | Every time I need newgrp, I forget its name but I remember it's like login for groups - newgrp(1) already cross-references login(1). MFC after: 2 days Notes: svn path=/head/; revision=174105
* Remove _SOLARIS_C_SOURCE now that it doesn't do anything in FreeBSDJohn Birrell2007-11-281-1/+0
| | | | | | | | | headers. All OpenSolaris compatibility comes via the set of specific compatibility headers in src/compat/opensolaris and src/sys/compat/opensolaris. Notes: svn path=/head/; revision=174059
* Fix -jX when makefiles are remade.Max Khon2007-11-251-0/+16
| | | | Notes: svn path=/head/; revision=173919
* Nuking the temporary pointer once it is properly tracked in local storage.Tai-hwa Liang2007-11-221-0/+1
| | | | | | | | | | | | | | | | This should fix the double free() bug where there's no tailing newline(\n) character: current# echo -n test | tail testAssertion failed: (run->magic == ARENA_RUN_MAGIC), function arena_dalloc, file /usr/src/lib/libc/stdlib/malloc.c, line 2448. Abort (core dumped) Reviewed by: kib MFC after: 3 days Notes: svn path=/head/; revision=173838
* These are the things that the tinderbox has problems with because itJohn Birrell2007-11-201-0/+1
| | | | | | | | | | | doesn't use the default CFLAGS which contain -fno-strict-aliasing. Until the code is cleaned up, just add -fno-strict-aliasing to the CFLAGS of these for the tinderboxes' sake, allowing the rest of the tree to have -Werror enabled again. Notes: svn path=/head/; revision=173766
* Generate code that doesn't fail gcc 4.2's strict aliasing test.John Birrell2007-11-201-4/+10
| | | | Notes: svn path=/head/; revision=173761
* Reduce the WARNS levels in a couple of places so that we can enableJohn Birrell2007-11-181-1/+1
| | | | | | | -Werror at higher WARNS levels like we did before gcc4 was imported. Notes: svn path=/head/; revision=173716
* Use variable types which match the function prototypes.John Birrell2007-11-172-2/+4
| | | | Notes: svn path=/head/; revision=173712
* Resolve conflicts; Update defines.h to reflect latest change.Xin LI2007-11-161-0/+9
| | | | Notes: svn path=/head/; revision=173685
* Fix (uncritical) potential buffer overflow: the length of "buf" was notStefan Eßer2007-11-151-1/+1
| | | | | | | | extended when "jaiL" was added to fmt_flags(). MFC after: 1 week Notes: svn path=/head/; revision=173627
* - Steal short description from POSIX; it's more technical and wasRuslan Ermilov2007-11-131-4/+4
| | | | | | | | easier to translate. - Fix some markup nits. Notes: svn path=/head/; revision=173581
* write(1) needs to strip off the leading /dev/ from the tty name for theJohn Baldwin2007-11-121-3/+2
| | | | | | | | | | | | | | | | current tty as returned from ttyname(3) so it can try to avoid writing to the current tty if possible. Previously, it did this by trimming off any leading directory (effectively performing a basename(3) on the path returned from ttyname(3)). However, this chopped off too much of the path for ttys who have directories in their name such as pts(4). Instead, just strip off the leading /dev/ from the path returned by ttyname(3). This fixes write(1) when using pts(4). MFC after: 1 week Reported by: rwatson Notes: svn path=/head/; revision=173572
* Fix a typo.Ruslan Ermilov2007-11-091-1/+1
| | | | Notes: svn path=/head/; revision=173506
* - Fix documentation to match code. Specifically, -c doesn't haveRuslan Ermilov2007-11-091-21/+15
| | | | | | | | | | to be specified together with either -u or -t to have an effect, and exit status of 2 is not possible after a Perl->C conversion. - While here, fix markup. Notes: svn path=/head/; revision=173504
* Fix numerous bugs when parsing options and arguments.Ruslan Ermilov2007-11-091-9/+19
| | | | Notes: svn path=/head/; revision=173502
* Use static storage-class specifier where appropriate.Diomidis Spinellis2007-11-084-10/+10
| | | | | | | Found by: CScout Notes: svn path=/head/; revision=173439
* Make function's definition follow its declared visibility.Diomidis Spinellis2007-11-081-1/+1
| | | | | | | Found by: CScout Notes: svn path=/head/; revision=173438