* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: master.c,v 1.156 2005/07/12 01:00:15 marka Exp $ */
+/* $Id: master.c,v 1.157 2005/08/23 04:05:49 marka Exp $ */
/*! \file */
return (ISC_R_SUCCESS);
}
-isc_result_t
+static isc_result_t
load_raw(dns_loadctx_t *lctx) {
isc_result_t result = ISC_R_SUCCESS;
isc_boolean_t done = ISC_FALSE;
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: a_1.c,v 1.3 2005/06/05 00:01:54 marka Exp $ */
+/* $Id: a_1.c,v 1.4 2005/08/23 04:05:49 marka Exp $ */
/* by Bjorn.Victor@it.uu.se, 2005-05-07 */
/* Based on generic/soa_6.c and generic/mx_15.c */
/* 16-bit octal address */
RETERR(isc_lex_getoctaltoken(lexer, &token, ISC_FALSE));
- if (token.value.as_ulong > 0xffff)
+ if (token.value.as_ulong > 0xffffU)
RETTOK(ISC_R_RANGE);
return (uint16_tobuffer(token.value.as_ulong, target));
}
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: mem.c,v 1.123 2005/07/12 01:00:18 marka Exp $ */
+/* $Id: mem.c,v 1.124 2005/08/23 04:05:50 marka Exp $ */
/*! \file */
* byte boundaries.
*/
- if (size == 0)
+ if (size == 0U)
return (ALIGNMENT_SIZE);
return ((size + ALIGNMENT_SIZE - 1) & (~(ALIGNMENT_SIZE - 1)));
}
* Did we hit the quota for this context?
*/
increment = NUM_BASIC_BLOCKS * ctx->mem_target;
- if (ctx->quota != 0 && ctx->total + increment > ctx->quota)
+ if (ctx->quota != 0U && ctx->total + increment > ctx->quota)
return (ISC_FALSE);
INSIST(ctx->basic_table_count <= ctx->basic_table_size);
* Add the remaining fragment of the basic block to a free list.
*/
total_size = rmsize(total_size);
- if (total_size > 0) {
+ if (total_size > 0U) {
((element *)next)->next = ctx->freelists[total_size];
ctx->freelists[total_size] = (element *)next;
ctx->stats[total_size].freefrags++;
/*
* memget() was called on something beyond our upper limit.
*/
- if (ctx->quota != 0 && ctx->total + size > ctx->quota) {
+ if (ctx->quota != 0U && ctx->total + size > ctx->quota) {
ret = NULL;
goto done;
}
memset(mem, 0xde, size); /* Mnemonic for "dead". */
#endif
(ctx->memfree)(ctx->arg, mem);
- INSIST(ctx->stats[ctx->max_size].gets != 0);
+ INSIST(ctx->stats[ctx->max_size].gets != 0U);
ctx->stats[ctx->max_size].gets--;
INSIST(size <= ctx->total);
ctx->inuse -= size;
* max. size (max_size) ends up getting recorded as a call to
* max_size.
*/
- INSIST(ctx->stats[size].gets != 0);
+ INSIST(ctx->stats[size].gets != 0U);
ctx->stats[size].gets--;
ctx->stats[new_size].freefrags++;
ctx->inuse -= new_size;
memset(ctx->stats, 0, (ctx->max_size + 1) * sizeof(struct stats));
if ((flags & ISC_MEMFLAG_INTERNAL) != 0) {
- if (target_size == 0)
+ if (target_size == 0U)
ctx->mem_target = DEF_MEM_TARGET;
else
ctx->mem_target = target_size;
(i == ctx->max_size) ? ">=" : " ",
(unsigned long) i, s->totalgets, s->gets);
if ((ctx->flags & ISC_MEMFLAG_INTERNAL) != 0 &&
- (s->blocks != 0 || s->freefrags != 0))
+ (s->blocks != 0U || s->freefrags != 0U))
fprintf(out, " (%lu bl, %lu ff)",
s->blocks, s->freefrags);
fputc('\n', out);
* PERFORMANCE OF THIS SOFTWARE.
*/
-/* $Id: string.c,v 1.15 2005/06/19 22:56:03 marka Exp $ */
+/* $Id: string.c,v 1.16 2005/08/23 04:05:50 marka Exp $ */
/*! \file */
isc_result_t
isc_string_copy(char *target, size_t size, const char *source) {
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
if (strlcpy(target, source, size) >= size) {
memset(target, ISC_STRING_MAGIC, size);
void
isc_string_copy_truncate(char *target, size_t size, const char *source) {
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
strlcpy(target, source, size);
isc_result_t
isc_string_append(char *target, size_t size, const char *source) {
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
REQUIRE(strlen(target) < size);
if (strlcat(target, source, size) >= size) {
void
isc_string_append_truncate(char *target, size_t size, const char *source) {
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
REQUIRE(strlen(target) < size);
strlcat(target, source, size);
va_list args;
size_t n;
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
va_start(args, format);
n = vsnprintf(target, size, format, args);
va_list args;
size_t n;
- REQUIRE(size > 0);
+ REQUIRE(size > 0U);
va_start(args, format);
n = vsnprintf(target, size, format, args);