When linking afsio many of the libraries specified in the EXELIB3
list were unnecessary. The only lib in the list that is required
is libcmd.lib. Rename EXELIB3 to LIBCMD and prune the rest.
Change-Id: I87bf0583f312d7b3dadc5581c08fedaa6b754c77
Reviewed-on: http://gerrit.openafs.org/9301
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
afsrpc.dll is supposed to be the multi-threaded dynamic loadable
version of the RX package. It has also included the RXAFS and
RXAFSCB client functions from src/fsint. Including the RXAFS* is
nice in theory but in practice the afsd_service.exe must link to
afsint.lib anyway in order to obtain access to RXAFSCB_ExecuteRequest()
which is part of the server portion. Linking to both results in
multiple instances of the same symbols in which case afsint.lib
must be linked to first and the dynamic version of the functions
are ignored.
The only other module that used RXAFS* functions from afsrpc.dll
is the adminutil library from the libadmin package. adminutil
doesn't implement the server functions but it can just as easily
link against afsint.lib.
Removing RXAFS* from afsrpc.dll results in a library that only
contains RX, RXSTATS, core xdr and rxkad.
This patchset also fixes some minor bugs:
1. $(UTILOBJS) were not being linked to the library due to
a typo.
2. Always use multi-thread safe versions of afsutil.lib
Change-Id: I5cc6d485a763d5a17735abd35d193fb7b0d280e5
Reviewed-on: http://gerrit.openafs.org/9300
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
afsauthent.dll exported:
pthread_recursive_mutex_lock
pthread_recursive_mutex_unlock
grmutex (DATA)
even though a dedicated afspthread.dll existed and all pthreaded
modules must link to afspthread.dll and not all link to
afsauthent.dll. Move these functions and the global mutex variable
to afspthread.dll to ensure that only one instance of the variable
is present in any binary.
Also remove from src/libafsauthent/NTMakefile the local building
of src/util object files and link to mtafsutil.lib.
Change-Id: I9f8e76165f9c1b1be7ed1a90cdaac03b629d9591
Reviewed-on: http://gerrit.openafs.org/9303
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If SDISK_SendFail fails before the pathname to the temporary file
has been constructed, then the failure handler will unlink stack
garbage, with variable results.
Initialise the string, and check to see if it has contents before
calling unlink
Change-Id: I1de898d5f0f0dc608e9c9c62dc66e6b4b9fdc5bf
Reviewed-on: http://gerrit.openafs.org/9299
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If afs_NewCell fails, then we can end up releasing a lock on a
section of memory that we have already freed. As this only happens
if the memory we're operating on is newly allocated and not yet
visible to anyone else, it is safe to release the lock before
starting to tidy things up.
Caught by coverity (#986054)
Change-Id: Ie8651c61790d57a9fd7bbbafcaf78e37b8222bae
Reviewed-on: http://gerrit.openafs.org/9298
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
When we call _StatCleanup on a stored statent structure, it
deletes the mutex, and frees the structure itself. This means it
can't be called with a locked structure as the mutex deletion
will fail, and then we'll try to reference freed memory when we
later unlock that mutex.
Fix this by unlocking the mutex before calling _StatCleanup. This
is safe because the only reference to the structure visible to other
threads must have been deleted by the time we reach this point.
Caught by coverity (#986058, #986059)
Change-Id: I346d4c8a7cd478db044af919662c1cf1c093e205
Reviewed-on: http://gerrit.openafs.org/9297
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If we have an input file which contains a group membership line
(with a leading space) before any group definitions occur, pt_util
would use stack garbage as the group to create these members in.
Avoid this by requiring the presence of a group line before any
membership lines.
Caught by coverity (#92180, #986000, #92248)
Change-Id: I536f089d67041dbf90f35b6dfeed5ba3303318a8
Reviewed-on: http://gerrit.openafs.org/9296
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If there isn't sufficient data in the input line to satisfy sscanf,
fail with an error, rather than continuing with potentially corrupt
data.
Change-Id: I5f963b5623176ac7631693b093d23cf9f0405edc
Reviewed-on: http://gerrit.openafs.org/9295
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
krb_write_ticket_file uses a fixed length buffer to store the name
of the ticket file, but copies into this from an environment variable.
Remove the fixed length buffer, and use a mixture of the variable
itself, and dynamically allocated strings.
Caught by coverity (#985909)
Change-Id: I997fd1812c45e730db39497a27a5e168f102fee5
Reviewed-on: http://gerrit.openafs.org/9294
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Refactor the code which returns a failure from afsconf_Open into
a single section, rather than having multiple copies through out
the routine.
Change-Id: I70b3fec98321bf89e6d59055545d5d4193026d28
Reviewed-on: http://gerrit.openafs.org/9293
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If we fallback to the .AFSCONF file in the user's homedirectory,
the results of getenv("HOME") are copied into a fixed length string,
without checking for overflows.
Instead of risking this, just use asprintf to dynamically construct
a string, and free it when we are done.
Caught by coverity (#985905)
Change-Id: Id8769ede841165d3ff3104143e55767d550d6f87
Reviewed-on: http://gerrit.openafs.org/9292
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Get rid of a buffer overflow in the bos_util utility, by just
printing the key from the 'tbuffer' string, rather than copying
it into 'x' which is too small for it.
Change-Id: Ia364fb63edb9e40a887e77aad833689a99b4ea7c
Reviewed-on: http://gerrit.openafs.org/9291
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
readlink fills the buffer passed to it with a non-terminated string.
It can legitimately fill the whole of this buffer. So, if we require
a string to be NUL terminated, we must give readlink one less than
the string length so that the termination character can be safely
appended.
Caught by coverity (#985611)
Change-Id: Ie6c651a9c0fd94d83bd05395204341d71e353146
Reviewed-on: http://gerrit.openafs.org/9290
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Before freeing curr_fsData, check that it is non-NULL, rather than
checking prev_fsData in error.
Caught by coverity (#985289)
Change-Id: I8fb74ce0c4e447de65924f2afb6075213d839760
Reviewed-on: http://gerrit.openafs.org/9284
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If a key is bad, have SBOZO_ListKeys return an error, rather than
silently ignoring the result from ka_KeyCheckSum.
Caught by coverity (#988413)
Change-Id: Ifacc9bac654d2632bd31731995795b786d485327
Reviewed-on: http://gerrit.openafs.org/9270
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
A part of the current ListUsedIds code is:
range = abs(startId - maxId);
if (range < 0)
range = -range;
The only way abs() could return a negative value would be if its
argument was INT_MIN (-2147483648) to begin with, because -INT_MIN
cannot be represented in two's complement. However, calling
abs(INT_MIN) is undefined behavior in C [see C99 7.20.6.1], and for
that matter, so would be computing -range (-INT_MIN) in that case,
so we could still be left with a negative range value.
Luckily, (startId - maxId) can never be INT_MIN. If startId < 0,
then maxId <= startId, so in the worst case, when maxId = INT_MIN
and startId = -1, (startId-maxId)=INT_MAX. If startId >= 0, then
maxId >= startId, so in the worst case, when maxId = INT_MAX and
startId = 0, (startId-maxId)=-INT_MAX=INT_MIN+1.
This patch removes the useless if statement.
Change-Id: Ia754fcf3e59354afb40dbbbb95623e27285a5f82
Reviewed-on: http://gerrit.openafs.org/9289
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Simon Wilkinson <simonxwilkinson@gmail.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
When reading a standard tag, make sure and catch an EOF error
from iod_getc. Otherwise we'll end up trying to parse 0xFF as a
tag length.
Caught by coverity (#985603)
Change-Id: Iae0b1bf71ed495b4f454975a1bfe3aef8fca3e9e
Reviewed-on: http://gerrit.openafs.org/9275
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
When using pt_util's ubik shim, if we're creating a new ubik label
make sure to zero the whole structure before writing it out to disk.
Otherwise we get a shorts worth of stack garbage in the resulting
file.
Caught by coverity (#986010)
Change-Id: I0abb8b7968d4f25c97dc0927d63dd01099b829b7
Reviewed-on: http://gerrit.openafs.org/9274
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
The documented abbreviation '-c' for '-cell' no longer works since
the -config option was added. Add a parm alias '-c' to restore
compatibility with previous syntax.
Change-Id: Ie98e470d204ea2186a95668bba2581cf3e88f729
Reviewed-on: http://gerrit.openafs.org/9276
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Coverity gets confused between ubik/ubik.c and ptserver/ubik.c,
and produces a load of false positives. Rename the ptserver ubik
shim (which is only used by pt_util) in order to reduce this
confusion.
Change-Id: Ida606fccebcb4edfed706405424ff3ee4858020f
Reviewed-on: http://gerrit.openafs.org/9273
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If we can't create the bozo daemon thread, then don't keep going
regardless. Just warn the user and exit.
Caught by coverity (#988414)
Change-Id: I46445b1744f7c3c944e917b33a6fc6fb669df002
Reviewed-on: http://gerrit.openafs.org/9269
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
If ubik_VL_GetVolumeId fails in the vos ProcessEntries routine,
report the failure and give up, rather than continuing with a
0 maxVolid
Caught by coverity (#988417)
Change-Id: I281e1c518813f9d7fab46e4f87a091fac6b3a754
Reviewed-on: http://gerrit.openafs.org/9268
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
The ubik disk header contains a padding field, which is never
zeroed before being written out to disk. This means that there is
a shorts worth of stack garbage in every ubik label!
Just zero the whole structure with memset before we populate it.
Caught by coverity (#986011)
Change-Id: Ib9f8b45111a83178372409c717c30ccb6a1044f4
Reviewed-on: http://gerrit.openafs.org/9272
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
When we extend a file, we write a single byte of data to it - tlen
is used as a source for this single byte. However, in the current
code, tlen is used uninitialised. Set it to 0, so we don't write a
byte of stack garbage.
Caught by coverity (#986015)
Change-Id: I11480a5ba0a5544437e18a6b314ff98ba6256df0
Reviewed-on: http://gerrit.openafs.org/9271
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
If the VIOC_FILE_CELL_NAME pioctl fails in fs mkmount, return an
error to the caller, instead of ploughing on with potentially bad
data.
Caught by coverity (#988418)
Change-Id: I68df5dd26d955db860dd016c76109f7d262bad17
Reviewed-on: http://gerrit.openafs.org/9267
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
When afscp_FindCallBack sets its return-by-reference value to NULL,
it should do so to the value itself, not the pointer to it.
Caught by coverity (#988419)
Change-Id: I6b227465d7aa945d871b2db1cc4d1357cae493d3
Reviewed-on: http://gerrit.openafs.org/9266
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
The imported code form Heimdal that forms our config file parser
and kernel rfc3961 library now makes use of krb5_enomem. Provide
an implementation so we build again ...
Change-Id: Ie7162d73aa97e6f7594c0e7c68ed6939f57ae884
Reviewed-on: http://gerrit.openafs.org/9265
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
This commit updates the code imported from heimdal to
66f4c441e9e0de68fbcf81763642779ac5c33631 (git2svn-syncpoint-master-199-g66f4c44)
Upstream changes are:
Kumar Thangavelu (1):
unning "kinit --fast-armor-cache=xxx" against a Win2K3 domain resulted in a crash with the attached backtrace. FAST is not supported with RC4 keys which are used in Win2K3. The code already handles this but the error code is not propagated up the stack.
Love Hornquist Astrand (1):
add socket_set_nonblocking
Roland C. Dowdeswell (3):
Optimise _krb5_n_fold() a bit.
Use krb5_enomem() more consistently in lib/krb5.
Further improvements to lib/krb5/n-fold.c:
Change-Id: I3b652e3ea3c84a939c4988bc8c24b3edee06446f
Reviewed-on: http://gerrit.openafs.org/9264
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: Derrick Brashear <shadow@your-file-system.com>
The _afscrypto_strdup helper function was failing to alloc enough
space for the string's trailing NUL, and to copy that NUL over.
Caught by coverity (#985580)
Change-Id: I61c9a96275a79682a9521846ab52615ea5bc061d
Reviewed-on: http://gerrit.openafs.org/9263
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
XVolListPartitions uses partList to maintain a list of partition
IDs - it does not use the partFlags field. Make it clear when we
populate the partEntries field that we are only copying the
partition list.
Caught by coverity (#986030)
Change-Id: I8c46ee5c220f0cb2b65943ad5faa80877ca46685
Reviewed-on: http://gerrit.openafs.org/9262
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Don't assign command syntax objects to 'ts' if we're not going
to add any parameters to them
Change-Id: I69f6e090fc115ab213c1f20dc46da81f2878e0a3
Reviewed-on: http://gerrit.openafs.org/9260
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
The 'bytesread' variable is set by all code paths, so don't bother
assigning a default value each time we pass through the loop
Caught by clang-analyzer
Change-Id: I8b79bc888ba23e2bcfa9befb5bf034db8f3ca3f8
Reviewed-on: http://gerrit.openafs.org/9259
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
We can't do anything if cleaning up the clone volume fails, so
don't bother storing the error code.
Caught by clang-analyzer
Change-Id: I5249dbad9a1bb732aba73e7a09f74c83e606b45d
Reviewed-on: http://gerrit.openafs.org/9258
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
matchLength is set regardless of what the separator is, so we don't need
to provide a default value.
Caught by clang-analyzer
Change-Id: Iac8fe8db8832cf2b3347ec1bdacc7245bddf542b
Reviewed-on: http://gerrit.openafs.org/9257
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
code is set to a real value on every code path, so don't bother
initialising it to 0 midway through the function.
Change-Id: I334286f2ae854c57df781af8df78e5a1bf8e9b2b
Reviewed-on: http://gerrit.openafs.org/9256
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
In UV_RestoreVolume2, there is a success flag whose only use is ...
success = 0
[ ... ]
success = 1
if (success) {
[ ... ]
}
It's pointless, so just remove it, and one clang warning
Caught by clang-analyzer
Change-Id: I7d57531c4dfb8955b813d534ad3b72b182fdbc76
Reviewed-on: http://gerrit.openafs.org/9255
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
The blockaddr iterator is initialised as part of the for loop.
Don't also initialise it immediately before.
Caught by clang-analyzer
Change-Id: I97e7ced15fe204b3b2d797abbdce8b3f9a2b0c8d
Reviewed-on: http://gerrit.openafs.org/9253
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Change f498c18a6f attempted to fix
a problem with using an inappropriate function to copy the
ktc_principal value 'principal' into the d.dumper structure element.
Originally the code read:
principal_hton(&principal, &d.dumper)
which copies the 'host' principal principal into the 'net' structure
d.dumper. However, this was changed to
principal = d.dumper
Which populates 'principal' with whatever garbage is in the d.dumper
structure.
Fix this so that the assignment is done the right way around.
Caught by clang-analyzer
Change-Id: Id9865a36b5a9351d013c695ed301b627ddc4a915
Reviewed-on: http://gerrit.openafs.org/9252
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
We don't need to maintain two copies (entryAddr and nextEntryAddr)
of the entry address - rework the while loop so we just use one,
and make clang a little happier
Caught by clang-analyzer
Change-Id: I6f5d76e114ad09a4fd3fc36b4d64f63daa9e1e78
Reviewed-on: http://gerrit.openafs.org/9251
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
The 'found' sentinel in h_stateVerifyUuidHash is unused, because
as soon as we set it, we jump out to the 'done' label. Simplify the
function's logic, and remove a static analysis warning, by just
removing the variable.
Caught by clang-analyzer
Change-Id: I02e5ccf857f5d84cd24975b7a1b9d516624ecd64
Reviewed-on: http://gerrit.openafs.org/9250
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
offset is simply used as a copy of nextOffset for the GetText
function call. We don't need to initialise it to 0 at the start of
the loop (and arguably, as it is passed to the function by value,
we could just remove the copy entirely)
Caught by clang-analyzer
Change-Id: I137ea3ba1ff44d94b90287d9735db69d6ff8717d
Reviewed-on: http://gerrit.openafs.org/9249
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
We never use the value of mvFlag once the string has been restored,
so don't bother reseting it.
Caught by clang-analyzer
Change-Id: I12db6957c9b8ec3bb9c43f10d9e9754d4afa3ed7
Reviewed-on: http://gerrit.openafs.org/9248
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Rather than silently ignoring the failure of
afsconf_GetExtendedCellInfo, and then using garbage cell
configuration, just fail to start if afsconf can't parse the
config directory.
Change-Id: Ib3d26bc67844de10f7eb8c2ef555c5e607e4bf61
Reviewed-on: http://gerrit.openafs.org/9247
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Don't initialise code immediately before we assign a real value
to it various UV_ functions
Caught by clang-analyzer
Change-Id: I91d9300715d44fafd73b1a61be548589468e3209
Reviewed-on: http://gerrit.openafs.org/9246
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
If we can't start the keep alive thread, in either the LWP or
pthread versions of a code, report an error and exit instead of
carrying on regardless.
Caught by clang-analyzer
Change-Id: I0a25a236aadeedf10d3c0c129d716b1397c9a4e3
Reviewed-on: http://gerrit.openafs.org/9245
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
All of these *Ptr values are reset upon each iteration of the
while loop, so we don't need to NULL them immediately before
we go around again.
Caught by clang-analyzer
Change-Id: Iaa5ff6c7b154072e23eae272031919b424568eff
Reviewed-on: http://gerrit.openafs.org/9244
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
In commit c753d398f2 the
AFSDirectoryCB.DirOpenReferenceCount was split and the
NameArrayReferenceCount field was added. However, it failed to modify all
of the DirOpenReferenceCount checks prior to calling AFSDeleteDirEntry()
to include a check on the NameArrayReferenceCount. This patchset corrects
that oversight.
Change-Id: I8db1a68e5240088bcfeb226bd1eafac0c83a0b69
Reviewed-on: http://gerrit.openafs.org/9254
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
Tested-by: Jeffrey Altman <jaltman@your-file-system.com>
Despite what the static analyzer thinks, ka_CellToRealm can't be
called with a NULL realm. Just add an assert to close down that
code path, and stop it from producing an error.
Change-Id: Ifc8cf7e5dca5ae29eaaa91c5b238a97197d89ee3
Reviewed-on: http://gerrit.openafs.org/9174
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>