if ((attrType & amount) != 0) {
len = sizeof this->xattrValue;
wrapCall(attr_get(lpath.c_str(), entry->a_name, this->xattrValue, &len, follow ? 0 : ATTR_DONTFOLLOW), "could not get extended attribute '%s' on '%s'", entry->a_name, path.c_str());
- debug("'%s' (type %d) = '%.*s'", entry->a_name, attrType, len, this->xattrValue);
+ //debug("'%s' (type %d) = '%.*s'", entry->a_name, attrType, len, this->xattrValue);
attrValue.assign(this->xattrValue, len);
xattrs[entry->a_name] = attrValue;
}
len = sizeof this->xattrValue;
wrapCall(attr_get(lpath.c_str(), key.c_str(), this->xattrValue, &len, flags), "could not get extended attribute '%s' on '%s'", key.c_str(), path.c_str());
- debug("got '%s' = '%.*s'", key.c_str(), len, this->xattrValue);
+ //debug("got '%s' = '%.*s'", key.c_str(), len, this->xattrValue);
attrValue.assign(this->xattrValue, len);
return attrValue;
void VfsCatalog::vfsSetXattr(const std::string& path, const std::string& lpath, const std::string key, const std::string value, int flags) {
switch (flags & (ATTR_REPLACE | ATTR_CREATE)) {
case ATTR_REPLACE:
- debug("replacing '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
+ //debug("replacing '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
wrapCall(attr_set(lpath.c_str(), key.c_str(), value.c_str(), value.size(), flags), "could not replace extended attribute '%s' on '%s'", key.c_str(), path.c_str());
break;
case ATTR_CREATE:
- debug("creating '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
+ //debug("creating '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
wrapCall(attr_set(lpath.c_str(), key.c_str(), value.c_str(), value.size(), flags), "could not create extended attribute '%s' on '%s'", key.c_str(), path.c_str());
break;
default:
- debug("setting '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
+ //debug("setting '%s' -> '%s' on '%s'", key.c_str(), value.c_str(), lpath.c_str());
wrapCall(attr_set(lpath.c_str(), key.c_str(), value.c_str(), value.size(), flags), "could not set extended attribute '%s' on '%s'", key.c_str(), path.c_str());
break;
}
if (attr_remove(lpath.c_str(), key.c_str(), flags) == -1) {
if (errno != ENOATTR)
vfsThrowErrno("could not remove extended attribute '%s' on '%s'", key.c_str(), path.c_str());
- debug("'%s' not exists on '%s'", key.c_str(), lpath.c_str());
+ //debug("'%s' not exists on '%s'", key.c_str(), lpath.c_str());
} else {
- debug("'%s' removed from '%s'", key.c_str(), lpath.c_str());
+ //debug("'%s' removed from '%s'", key.c_str(), lpath.c_str());
}
}