diff options
Diffstat (limited to 'debian/patches/xattr0003-Small-fixes.patch')
-rw-r--r-- | debian/patches/xattr0003-Small-fixes.patch | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/debian/patches/xattr0003-Small-fixes.patch b/debian/patches/xattr0003-Small-fixes.patch new file mode 100644 index 00000000..77a5e433 --- /dev/null +++ b/debian/patches/xattr0003-Small-fixes.patch @@ -0,0 +1,44 @@ +From 19f7a0af88ebd92223c89c7134d5ba15b781c8d9 Mon Sep 17 00:00:00 2001 +From: Justus Winter <justus@gnupg.org> +Date: Thu, 14 Jul 2016 23:53:28 +0200 +Subject: [PATCH hurd 3/6] Small fixes + +--- + ext2fs/inode.c | 15 +++++++-------- + 1 file changed, 7 insertions(+), 8 deletions(-) + +diff --git a/ext2fs/inode.c b/ext2fs/inode.c +index 175bc26..fd28295 100644 +--- a/ext2fs/inode.c ++++ b/ext2fs/inode.c +@@ -578,20 +578,19 @@ diskfs_set_translator (struct node *np, const char *name, unsigned namelen, + } + + /* Use xattr to store translator record, with key "gnu.translator" */ +- err = ext2_get_xattr(np, "gnu.translator", NULL, &len); +- if (err && err != ENODATA) +- return err; +- +- if (namelen && err == ENODATA) ++ if (namelen) + { +- err = ext2_set_xattr(np, "gnu.translator", name, namelen, XATTR_CREATE); ++ err = ext2_set_xattr (np, "gnu.translator", name, namelen, 0); + + np->dn_stat.st_mode |= S_IPTRANS; + np->dn_set_ctime = 1; + } +- else if (!namelen && !err) ++ else + { +- err = ext2_set_xattr(np, "gnu.translator", NULL, 0, 0); ++ err = ext2_set_xattr (np, "gnu.translator", NULL, 0, 0); ++ ++ np->dn_stat.st_mode &= ~S_IPTRANS; ++ np->dn_set_ctime = 1; + } + + diskfs_end_catch_exception (); +-- +2.8.1 + |