Hartmut Brandt
179078e76d
Change the return value of Var_Subst to return a Buffer instead
...
of a char *.
Patch: 7.49
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-25 13:16:56 +00:00
Sergey Matveychuk
88565cf2d1
Fix a typo in my last commit.
...
Reported by: ceri
2005-02-24 18:17:41 +00:00
Sergey Matveychuk
524cfc25d0
Put my birthday into the pool.
...
Sorry guys, USSR idiosyncrasy.
2005-02-24 17:08:39 +00:00
Hartmut Brandt
d057118357
Var_Parse: Separate different error states by introducing an else block
...
after a return. Move assignments to {freePtr, dynamic, start} closer to the
return statements to clarify which variables are actually used for
communication between the losely coupled blocks of the code. Clear up
an if-expression to make common structures of the conditions clearer.
Use strchr instead of switch statements to check for a character beeing
a member of a set.
Patches: 7-62.2, 7-62.3, 7-64, 7-65.1, 7-65.2
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-24 16:05:45 +00:00
Hartmut Brandt
a65e9283c5
Push assignments to just before the returns from the function to
...
get it clearer what variables are actually needed.
Patches: 7.62.2, 7.62.3
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-24 10:35:39 +00:00
Hartmut Brandt
0cb1c98b7a
Fix wording of a comment.
...
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-24 10:30:23 +00:00
Hartmut Brandt
9a2bfd7ef5
Replace the calls to Lst_ForEach with the new LST_FOREACH macro and
...
fix the prototype for Compat_RunCommand to take the actual argument
types instead of void *.
2005-02-24 10:23:31 +00:00
Tom Rhodes
c566c001e6
Add better mdoc(7) mark up, clean up wording, better describe the effects
...
of some arguments.
PR: 47705
Based on a patch submitted by: Gary W. Swearingen <swear@attbi.com>
Glanced at by: simon
2005-02-23 22:40:45 +00:00
Hartmut Brandt
592dcf0422
Use the LST_FOREACH macro instead of the Lst_ForEach function
...
and so get rid of the ForExec helper function by inlining it
into For_Run.
2005-02-23 14:03:18 +00:00
Hartmut Brandt
7175fefe00
Style: fix indent, use tabs instead of space+tab for aligning things.
...
Add a couple of comments.
2005-02-23 13:58:56 +00:00
Hartmut Brandt
09dd1bb9a1
Fix the indendation of some multi-line comments.
...
Noted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-23 10:20:58 +00:00
Ruslan Ermilov
6fe37d1365
Add endianness support to cap_mkdb(1), useful for cross builds.
2005-02-22 23:29:54 +00:00
Gleb Smirnoff
a97719482d
Add CARP (Common Address Redundancy Protocol), which allows multiple
...
hosts to share an IP address, providing high availability and load
balancing.
Original work on CARP done by Michael Shalayeff, with many
additions by Marco Pfatschbacher and Ryan McBride.
FreeBSD port done solely by Max Laier.
Patch by: mlaier
Obtained from: OpenBSD (mickey, mcbride)
2005-02-22 13:04:05 +00:00
Hartmut Brandt
6a1865cdbb
Fix the prototypes by addings some constness. This should have been
...
committed together with the commit to dir.c:1.48.
2005-02-22 08:17:05 +00:00
Hartmut Brandt
e4597ce6ea
Use the new LST_FOREACH macro throughout the file and replace calls to
...
Lst_ForEach and Lst_Find.
2005-02-22 08:00:06 +00:00
Hartmut Brandt
36120d91e5
Invent the LST_FOREACH macro for looping through a list. In contrast
...
to the Lst_ForEach function this macro reduces the number of function
calls per invocation by N + 1 (where N is the number of list elements)
and increases code locality thereby increasing readability and
(maybe) performance.
2005-02-22 07:58:53 +00:00
Paul Saab
043da612df
Fix an overflow when calculating the number of kilobytes from the
...
number of pages.
Obtained from: Yahoo!
2005-02-21 14:35:00 +00:00
Hartmut Brandt
1d2a8153d3
Style: fix indendation to be 8 and use tabulators. Fix lines longer than
...
80 characters and slightly reorder functions to get rid of static
prototypes.
2005-02-21 13:36:22 +00:00
Hartmut Brandt
6abaece6ae
Forgot to set *freePtr to FALSE in another place.
...
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-21 08:10:21 +00:00
Hartmut Brandt
436834581b
Fix a bug in handling archive members: when a member was not found
...
when looking into an already hashed archive, the code tried to use
the name shortened to the maximum length allowed for the archive.
Unfortunately it passed a buffer of junk to the hashing routine when
the name actually wasn't too long. Theoretically this could lead to
a false positive.
2005-02-21 08:06:34 +00:00
Ruslan Ermilov
02172b19b8
Fixate the hash bucket size to 4K. We were using the default,
...
which is stat.st_blksize (i.e., PAGE_SIZE).
This change causes the .db files that were cross-compiled on
another platform to be identical to the natively built ones.
Tested on: alpha->amd64 build
2005-02-19 23:59:49 +00:00
Hajimu UMEMOTO
1b92360adc
simply ignore unknown address family.
...
MFC after: 1 week
2005-02-19 16:54:26 +00:00
Hajimu UMEMOTO
511912ad5c
teach IPv6 to `systat -netstat'.
...
Tested by: kuriyama
MFC after: 1 week
2005-02-19 15:10:19 +00:00
Garrett Wollman
456f9a140f
Support correct programming environment name for amd64.
...
MFC after: 3 days
2005-02-18 21:53:05 +00:00
Tim Kientzle
b432e867aa
Document the --null, --one-file-system, and -I options.
...
Clarify that -T can be used in 'x' mode as well as 'c' mode.
2005-02-18 19:19:45 +00:00
Hartmut Brandt
7f2e1af188
Push the assignments of some variables down into the sub-blocks where
...
it is actually needed. This makes clear in which subblocks the variables
are not needed and which can easier be split out.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-18 15:32:06 +00:00
Hartmut Brandt
1aaa4432a5
Push down variables into local scope in Var_Parse to make their
...
liveness clear for splitting up this monster function.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-18 07:33:43 +00:00
Herve Quiroz
f812d8f8c6
Add myself to the calendar
2005-02-17 16:38:56 +00:00
Hartmut Brandt
5fdd47f89b
Whitespace cleanup: substitute mixed tabs and spaces by canonical
...
whitespace and line up some variable definitions.
2005-02-17 12:35:32 +00:00
Hartmut Brandt
b2a8c56e3a
Move error case to begin of if-else chain. Do not needless initialize
...
startc, but only at the place where the initialisation is needed. Remove
a needless else.
Submitted by: Max Okumoto <okumoto@ucsd.edu> (partly)
2005-02-17 12:31:53 +00:00
Hartmut Brandt
3ff4a47ba0
Fix two typos in comments.
...
Submitted by: ru & Max Okumoto <okumoto@ucsd.edu>
2005-02-17 09:09:34 +00:00
Hartmut Brandt
768820f8c7
Sort out the error case that a single '$' was passed a little bit
...
earlier instead of mixing its handling with other cases.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-17 09:01:19 +00:00
Hartmut Brandt
46f05faa3a
Mostly stylistic issues: move a variable into local scope, make
...
condition positive and fix long lines.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-16 17:20:09 +00:00
Hartmut Brandt
5e431bae8f
Better version of the patch in 1.117: bring a variable into local scope
...
to prepare for function splitting and slightly reorganise the code
in anticipation of Var_Subst returning a Buffer.
Submitted by: Max Okumoto <okumoto@ucsd.edu> (with slight changes)
2005-02-16 12:39:32 +00:00
Stefan Farfeleder
78e3eed071
Fix most cases where the address of an int is passed to a function expecting a
...
socklen_t * argument.
2005-02-14 17:42:58 +00:00
Ruslan Ermilov
36a142c455
Expand contractions.
2005-02-13 23:45:54 +00:00
Ruslan Ermilov
0227791b40
Expand *n't contractions.
2005-02-13 22:25:33 +00:00
Xin LI
41fe9ea15f
New order after _netcat has been changed to _nc: sort the list.
...
Submitted by: ru
Pointy hat to: me
2005-02-13 13:42:20 +00:00
Hartmut Brandt
0d63385639
Back out the previous commit. There is an obvious bug in it.
...
Pointy hat to: harti
2005-02-13 13:33:56 +00:00
Xin LI
a1635c6837
Spell the variable as underscore plus their possible value, to follow
...
the style nearby.
Submitted by: ru
2005-02-13 10:11:21 +00:00
Xin LI
4457bf036b
Forgotten to commit this file during the last commit. Connect nc(1)
...
to build.
2005-02-13 07:12:23 +00:00
Hartmut Brandt
157e401636
Stylistic fixes: push variable into a local context (this part is going
...
to be split out into a function soon). Also there is no need to write
back the colon that we have NUL-ed - the string is going to be freed
anyway.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-11 17:03:18 +00:00
Hartmut Brandt
40fe2aa311
Convert several instances of negative logic to positive logic.
...
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-11 10:49:01 +00:00
Hartmut Brandt
26478079f7
Buffers are already NUL-terminated so there is no need to explicitely add
...
a NULL.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-10 17:01:46 +00:00
Hartmut Brandt
ed293d7304
Mostly stylistic nits in preparation for splitting up Var_Parse:
...
use a more consistent style with regard to *str and str[0];
simplify code by introducing a temporary variable;
shift a break around and add braces where appropriate.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-10 17:00:16 +00:00
Ruslan Ermilov
48baa77217
Fixed usage().
2005-02-10 16:07:23 +00:00
Ruslan Ermilov
b7a311f2b8
Require at least one argument.
2005-02-10 16:04:22 +00:00
Hartmut Brandt
42e4f1252b
Let the buffer just use the default size by specifying 0 as the size
...
instead of specifying the default size explicitely.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-10 14:53:29 +00:00
Hartmut Brandt
c738c9b125
Mark the modification of the input string (which should really be const)
...
with a comment.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-10 14:52:14 +00:00
Hartmut Brandt
302288aba2
Style nits:
...
Move some assignments nearer to where they actually used. Convert a loop
from a for() to a while() to make it clearer and add braces to the long
body of it. Split assignment from variable declaration.
Submitted by: Max Okumoto <okumoto@ucsd.edu>
2005-02-10 14:50:34 +00:00