error2_SOURCES = error2.cc common.h common.cc
error4_SOURCES = error4.cc common.h common.cc
-xattrs1_SOURCES = xattrs1.cc xattrs_utils.cc xattrs_utils.h common.h common.cc
-xattrs2_SOURCES = xattrs2.cc xattrs_utils.cc xattrs_utils.h common.h common.cc
-xattrs3_SOURCES = xattrs3.cc xattrs_utils.cc xattrs_utils.h common.h common.cc
-xattrs4_SOURCES = xattrs4.cc xattrs_utils.cc xattrs_utils.h common.h common.cc
+xattrs1_SOURCES = xattrs1.cc xattrs-utils.cc xattrs-utils.h common.h common.cc
+xattrs2_SOURCES = xattrs2.cc xattrs-utils.cc xattrs-utils.h common.h common.cc
+xattrs3_SOURCES = xattrs3.cc xattrs-utils.cc xattrs-utils.h common.h common.cc
+xattrs4_SOURCES = xattrs4.cc xattrs-utils.cc xattrs-utils.h common.h common.cc
test_btrfsutils_SOURCES = test-btrfsutils.cc
#include <string.h>
#include <sys/xattr.h>
-#include "xattrs_utils.h"
+#include "xattrs-utils.h"
#include "common.h"
-void xattr_create(const char *name, const char *value, const char *path)
+
+void
+xattr_create(const char* name, const char* value, const char* path)
{
std::cout << "xa create: file:" << path << "," << name << "=" << value << "... ";
- check_zero(lsetxattr(path, name, (void *) value, strlen(value), XATTR_CREATE));
+ check_zero(lsetxattr(path, name, (void*) value, strlen(value), XATTR_CREATE));
std::cout << "done" << std::endl;
}
-void xattr_remove(const char *name, const char *path)
+
+void
+xattr_remove(const char* name, const char* path)
{
std::cout << "xa remove: file:" << path << "," << name << "... ";
check_zero(lremovexattr(path, name));
std::cout << "done" << std::endl;
}
-void xattr_replace(const char *name, const char *value, const char *path)
+
+void
+xattr_replace(const char* name, const char* value, const char* path)
{
std::cout << "xa replace: file:" << path << "," << name << "=" << value << "... ";
- check_zero(lsetxattr(path, name, (void *) value, strlen(value), XATTR_REPLACE));
+ check_zero(lsetxattr(path, name, (void*) value, strlen(value), XATTR_REPLACE));
std::cout << "done" << std::endl;
}
+++ /dev/null
-
-
-void xattr_create(const char *, const char *, const char *);
-
-void xattr_remove(const char *, const char *);
-
-void xattr_replace(const char *, const char *, const char *);
\ No newline at end of file