| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
| |
set an exclusive advisory lock on stdout. This will be used to guarantee
orderly writing to METALOG.
Sponsored by: DARPA, AFRL
Obtained from: NetBSD (mason)
|
|
|
|
|
|
|
|
| |
the -n option is specified and the destination file exists.
PR: bin/174489
Approved by: rstone (co-mentor)
MFC after: 2 weeks
|
|
|
|
| |
Noticed by: mckusick
|
|
|
|
|
|
| |
- Add -, to SYNOPSIS section.
MFC after: 2 weeks
|
|
|
|
|
|
| |
Otherwise with '-v' we print out the file name as if it was copied:
/tmp/2gb-card/M0132.CTG not overwritten
/mnt/DCIM/CANONMSC/M0132.CTG -> /tmp/2gb-card/M0132.CTG
|
|
|
|
| |
Discussed with: jilles
|
|
|
|
|
|
| |
with what we use in /usr/share/skel/dot.profile.
Discussed with: jilles
|
|
|
|
|
|
|
|
|
|
|
|
| |
If a loop contained certain commands (such as redirected compound commands),
the temporary memory for the redirection was not freed between iterations of
the loop but only after the loop.
Put a stackmark in evaltree(), freeing memory whenever a node has been
evaluated. Some other stackmarks are then redundant; remove them.
Example:
while :; do { :; } </dev/null; done
|
|
|
|
| |
Instead, call the only init function left directly from main().
|
| |
|
|
|
|
|
| |
- Update shadow copy of fmt_argv() prototype in w.c and fix calls for
additional parameter.
|
|
|
|
|
|
|
|
|
| |
command name of a thread from a multi-threaded process that doesn't have
an available argument list (such as kernel processes) and threads display
is enabled via -H.
Reviewed by: alfred, delphij, eric@vangyzen.net
MFC after: 1 week
|
|
|
|
|
|
|
| |
-P is an alternative to -H and -L, and it is implemented using the Hflag and Lflag variables.
Approved by: cperciva
MFC after: 3 days
|
|
|
|
|
|
| |
explicitly telling the compiler that we are on the exit route.
X-MFC: together with r245494
|
|
|
|
|
|
|
| |
static analyzer
Approved by: cperciva
MFC after: 3 days
|
|
|
|
|
|
|
|
| |
Instead of rechecking relative paths for all hashed utilities after a cd,
track if any utility in cmdtable depends on a relative path in PATH.
If there is such a utility, cd clears the entire table.
As a result, the '*' in hash no longer happens.
|
|
|
|
|
| |
Example:
false; echo $(echo $?; :)
|
|
|
|
| |
MFC after: 1 week
|
|
|
|
|
|
|
|
|
| |
An empty simple command was added and overwrote the exit status with 0.
This affects `...` but not $(...).
Example:
v=`false;`; echo $?
|
|
|
|
| |
this case skip the test as gcc complains it is always true.
|
|
|
|
|
|
| |
PR: 174787
Submitted by: Cody Rank
MFC after: 3 days
|
|
|
|
|
|
| |
Reviewed by: gjb
Requested by: gjb
MFC after: 1 week
|
|
|
|
|
|
|
|
| |
Accessing sys_siglist directly requires rtld to copy it from libc to the sh
executable's BSS. Also, strsignal() will put in the signal number for
unknown signals (FreeBSD-specific) so we need not do that ourselves.
Unfortunately, there is no function for sys_signame.
|
|
|
|
| |
Submitted by: Garrett Cooper
|
|
|
|
|
|
|
| |
If there is a write error on stdout, a message will be printed (to stderr)
and the exit status will be changed to 2 if it would have been 0 or 1.
PR: bin/158206
|
|
|
|
|
|
| |
define.
Reviewed by: jhb
|
|
|
|
| |
MFC after: 2 weeks
|
|
|
|
|
|
| |
Rework block count calculations to work correctly with small "block" sizes.
MFC after: 14 days
|
|
|
|
| |
MFC after: 3 days
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
if (exists AND (NOT f_option) AND
((not_writable AND input_is_terminal) OR i_option))
prompt
in particular, add the test for input_is_terminal
PR: bin/173039
Submitted by: Mark Johnston <markjdb@gmail.com>
Approved by: cperciva
MFC after: 3 days
|
|
|
|
|
|
|
| |
using the non-monetary separator returned by localeconv(3), typically
a comma or period.
MFC after: 14 days
|
| |
|
| |
|
|
|
|
| |
format strings, "period, space, space" in comment text, etc.
|
|
|
|
| |
Reminded by: jh@
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* The last character is not displayed.
* If the alias ends with itself (as a word), an infinite memory-eating loop
occurs.
If an alias is defined initially, a space is appended to avoid recursion but
this did not happen when an alias was later modified.
PR: bin/173418
Submitted by: Daniel F.
MFC after: 1 week
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
sorting order for time and name with the -t option. IEEE Std 1003.2
(POSIX.2) mandates that the -t option sort in descending order, and
that if two files have the same timestamp, they should be sorted in
ascending order of their names. The -r flag reverses both of these
sort orders, so they're never the same. This creates significant
problems for sequentially named files stored on FAT file systems,
where it can be impossible to list them in the order in which they
were created.
Add , (comma) option to print file sizes grouped and separated by
thousands using the non-monetary separator returned by localeconv(3),
typically a comma or period.
MFC after: 14 days
|
| |
|
|
|
|
|
| |
If this is a smaller type than int anyway, we can make it the smallest
possible.
|
|
|
|
|
|
|
|
| |
Although sufficient memory is available for a longer string in cmdname,
this is undefined behaviour anyway.
Side effect: for alignment reasons, an additional byte of memory is
allocated per hashed command.
|
|
|
|
| |
Obtained from: OpenBSD
|
|
|
|
|
|
|
|
|
|
| |
In addition to adding missing `static' keywords:
- bin/dd: Pull in `extern.h' to guarantee consistency with source file.
- libexec/rpc.rusersd: Move shared globals into an extern.h.
- libexec/talkd: Move `debug' and `hostname' into extern.h.
- usr.bin/cksum: Put counters in extern.h, as they are used by ckdist/mtree.
- usr.bin/m4: Move `end_result' into extern.h.
- usr.sbin/services_mkdb: Move shared globals into an extern.h.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In addition to adding `static' where possible:
- bin/date: Move `retval' into extern.h to make it visible to date.c.
- bin/ed: Move globally used variables into ed.h.
- sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings.
- usr.bin/calendar: Remove unneeded variables.
- usr.bin/chat: Make `line' local instead of global.
- usr.bin/elfdump: Comment out unneeded function.
- usr.bin/rlogin: Use _Noreturn instead of __dead2.
- usr.bin/tset: Pull `Ospeed' into extern.h.
- usr.sbin/mfiutil: Put global variables in mfiutil.h.
- usr.sbin/pkg: Remove unused `os_corres'.
- usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
|
|
|
|
|
|
|
|
|
|
|
| |
This self-written compiler warning, which is hopefully going to be
committed into LLVM sources soon, warns about potentially missing
`static' keywords, similar to -Wmissing-prototypes.
- bin/pax: Move external declaration of chdname and s_mask into extern.h.
- bin/setfacl: Move setfacl.c-specific stuff out of setfacl.h.
- sbin/mount_fusefs: Remove char *progname; use getprogname().
- others: add `static' where possible.
|
|
|
|
|
|
| |
Fixes a mandoc lint warning.
Discussed with: brueffer, Jason McIntyre <jmc@kerhand.co.uk>
|
|
|
|
| |
Original code by: Gleb Kurtsou
|
|
|
|
|
|
| |
Submitted by: pluknet
Approved by: kib (mentor)
X-MFC-With: r240645
|
|
|
|
|
| |
Approved by: kib (mentor)
MFC after: 1 week
|
|
|
|
|
|
|
| |
mntbuf can poit to memory allocated by getmntinfo(3) which can't be freed
PR: bin/171634
Approved by: cperciva (implicit)
|