From 4e55071879aae604b7b61c93dc815a357571cd88 Mon Sep 17 00:00:00 2001 From: Rene Mayrhofer Date: Tue, 25 May 2010 19:09:13 +0000 Subject: New upstream release. --- src/libstrongswan/chunk.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/libstrongswan/chunk.c') diff --git a/src/libstrongswan/chunk.c b/src/libstrongswan/chunk.c index 86436e997..ef69eb4e7 100644 --- a/src/libstrongswan/chunk.c +++ b/src/libstrongswan/chunk.c @@ -22,8 +22,7 @@ #include #include "chunk.h" - -#include +#include "debug.h" /* required for chunk_hash */ #undef get16bits @@ -222,7 +221,7 @@ bool chunk_write(chunk_t chunk, char *path, char *label, mode_t mask, bool force if (!force && access(path, F_OK) == 0) { - DBG1(" %s file '%s' already exists", label, path); + DBG1(DBG_LIB, " %s file '%s' already exists", label, path); return FALSE; } oldmask = umask(mask); @@ -231,20 +230,21 @@ bool chunk_write(chunk_t chunk, char *path, char *label, mode_t mask, bool force { if (fwrite(chunk.ptr, sizeof(u_char), chunk.len, fd) == chunk.len) { - DBG1(" written %s file '%s' (%d bytes)", + DBG1(DBG_LIB, " written %s file '%s' (%d bytes)", label, path, chunk.len); good = TRUE; } else { - DBG1(" writing %s file '%s' failed: %s", + DBG1(DBG_LIB, " writing %s file '%s' failed: %s", label, path, strerror(errno)); } fclose(fd); } else { - DBG1(" could not open %s file '%s': %s", label, path, strerror(errno)); + DBG1(DBG_LIB, " could not open %s file '%s': %s", label, path, + strerror(errno)); } umask(oldmask); return good; @@ -497,7 +497,7 @@ bool chunk_printable(chunk_t chunk, chunk_t *sane, char replace) * Described in header. * * The implementation is based on Paul Hsieh's SuperFastHash: - * http://www.azillionmonkeys.com/qed/hash.html + * http://www.azillionmonkeys.com/qed/hash.html */ u_int32_t chunk_hash_inc(chunk_t chunk, u_int32_t hash) { -- cgit v1.2.3