Package: star
Severity: normal
Tags: patch
When storing extended attributes (with -xattr-linux), star fails on symlinks
which are undefined (their target does not exist). This prevents /etc/tardumps
to be written, which is crucial for doing incremental backups.
The solution is to use llistxattr instead of listxattr in star/xattr.c. This
stores information about the symlink and not it's target, which is probably
desired anyway.
-- System Information:
Debian Release: testing/unstable
APT prefers testing
APT policy: (500, 'testing')
Architecture: i386 (i686)
Shell: /bin/sh linked to /bin/dash
Kernel: Linux 2.6.14.5masca
Locale: LANG=cs_CZ, LC_CTYPE=cs_CZ (charmap=ISO-8859-2)
diff -Naur star-1.5a67.orig/star/xattr.c newstar/star/xattr.c
--- star-1.5a67.orig/star/xattr.c 2005-09-03 00:29:35.000000000 +0200
+++ newstar/star/xattr.c 2006-01-16 10:01:46.000000000 +0100
@@ -61,7 +61,7 @@
info->f_xflags &= ~XF_XATTR;
info->f_xattr = NULL;
- list_len = listxattr(info->f_name, NULL, 0);
+ list_len = llistxattr(info->f_name, NULL, 0);
if (list_len < 0) {
if (!errhidden(E_GETXATTR, info->f_name)) {
if (!errwarnonly(E_GETXATTR, info->f_name))
@@ -74,7 +74,7 @@
return (FALSE);
}
alist = __malloc(list_len+2, "extended attribute");
- list_len = listxattr(info->f_name, alist, list_len);
+ list_len = llistxattr(info->f_name, alist, list_len);
if (list_len < 0) {
if (!errhidden(E_GETXATTR, info->f_name)) {
if (!errwarnonly(E_GETXATTR, info->f_name))