/*
- * $Id: cnid_cdb_lookup.c,v 1.2 2005-04-28 20:49:59 bfernhomberg Exp $
+ * $Id: cnid_cdb_lookup.c,v 1.5 2009-10-29 13:38:16 didg Exp $
*/
#ifdef HAVE_CONFIG_H
/* This returns the CNID corresponding to a particular file. It will
* also fix up the various databases if there's a problem. */
cnid_t cnid_cdb_lookup(struct _cnid_db *cdb, const struct stat *st, const cnid_t did,
- char *name, const int len)
+ char *name, const size_t len)
{
- char *buf;
+ unsigned char *buf;
CNID_private *db;
DBT key, devdata, diddata;
char dev[CNID_DEV_LEN];
cnid_cdb_update(cdb, id, st, did, name, len);
#ifdef DEBUG
- LOG(log_info, logtype_default, "cnid_lookup: Looked up did %u, name %s, as %u (needed update)", ntohl(did), name, ntohl(id));
+ LOG(log_debug9, logtype_default, "cnid_lookup: Looked up did %u, name %s, as %u (needed update)", ntohl(did), name, ntohl(id));
#endif
return id;
}