rpms/util-linux-ng/F-12 util-linux-ng-2.16-blkid-crypto.patch, NONE, 1.1 util-linux-ng-2.16-blkid-ntfs.patch, NONE, 1.1 util-linux-ng.spec, 1.65, 1.66 util-linux-ng-2.16-blkid-crypto.path, 1.1, NONE util-linux-ng-2.16-blkid-ntfs.path, 1.1, NONE
kzak
kzak at fedoraproject.org
Wed Dec 9 20:58:54 UTC 2009
Author: kzak
Update of /cvs/pkgs/rpms/util-linux-ng/F-12
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv22319
Modified Files:
util-linux-ng.spec
Added Files:
util-linux-ng-2.16-blkid-crypto.patch
util-linux-ng-2.16-blkid-ntfs.patch
Removed Files:
util-linux-ng-2.16-blkid-crypto.path
util-linux-ng-2.16-blkid-ntfs.path
Log Message:
* Wed Dec 9 2009 Karel Zak <kzak at redhat.com> 2.16.2-3
- fix typo in spec file
util-linux-ng-2.16-blkid-crypto.patch:
probe.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
--- NEW FILE util-linux-ng-2.16-blkid-crypto.patch ---
From: Scott James Remnant <scott at ubuntu.com>
Subject: [PATCH] libblkid: return first detected crypto device
Crypto devices may sometimes have multiple additional prober matches,
however just like RAID, there's no danger of activating the wrong one
since special help is needed to activate the block device before it
can be used.
Thus modify blkid_do_safeprobe() to break out of the loop when a
crypto device is detected, as it does already for RAID.
[kzak at redhar.com: - backport to 2.16.2 for Fedora-12]
Signed-off-by: Scott James Remnant <scott at ubuntu.com>
Signed-off-by: Karel Zak <kzak at redhat.com>
diff -up util-linux-ng-2.16.2/shlibs/blkid/src/probe.c.kzak util-linux-ng-2.16.2/shlibs/blkid/src/probe.c
--- util-linux-ng-2.16.2/shlibs/blkid/src/probe.c.kzak 2009-12-07 09:44:46.000000000 +0100
+++ util-linux-ng-2.16.2/shlibs/blkid/src/probe.c 2009-12-07 09:47:12.000000000 +0100
@@ -538,9 +538,9 @@ int blkid_do_probe(blkid_probe pr)
* (cannot be used in while()) and checks for ambivalen results (more
* filesystems on the device) -- in such case returns -2.
*
- * The function does not check for filesystems when a RAID signature is
- * detected. The function also does not check for collision between RAIDs. The
- * first detected RAID is returned.
+ * The function does not check for filesystems when a RAID or crypto signature
+ * is detected. The function also does not check for collision between RAIDs
+ * and crypto devices. The first detected RAID or crypto device is returned.
*/
int blkid_do_safeprobe(blkid_probe pr)
{
@@ -558,7 +558,7 @@ int blkid_do_safeprobe(blkid_probe pr)
}
count++;
- if (idinfos[pr->idx]->usage & BLKID_USAGE_RAID)
+ if (idinfos[pr->idx]->usage & (BLKID_USAGE_RAID | BLKID_USAGE_CRYPTO))
break;
if (!(idinfos[pr->idx]->flags & BLKID_IDINFO_TOLERANT))
intol++;
util-linux-ng-2.16-blkid-ntfs.patch:
ntfs.c | 18 +++---------------
1 file changed, 3 insertions(+), 15 deletions(-)
--- NEW FILE util-linux-ng-2.16-blkid-ntfs.patch ---
Backport from upstream to Fedora-12, original patch:
commit 832b3f2eb6a6c5f2e7d8db422767404320e45ced
Author: Karel Zak <kzak at redhat.com>
Date: Fri Nov 13 00:10:48 2009 +0100
libblkid: fix NTFS non-ASCII labels
Addresses-Red-Hat-Bug: #536797
Signed-off-by: Karel Zak <kzak at redhat.com>
diff -up util-linux-ng-2.16.2/shlibs/blkid/src/probers/ntfs.c.kzak util-linux-ng-2.16.2/shlibs/blkid/src/probers/ntfs.c
--- util-linux-ng-2.16.2/shlibs/blkid/src/probers/ntfs.c.kzak 2009-11-30 12:43:13.000000000 +0100
+++ util-linux-ng-2.16.2/shlibs/blkid/src/probers/ntfs.c 2009-12-07 10:34:10.000000000 +0100
@@ -65,10 +65,9 @@ static int probe_ntfs(blkid_probe pr, co
struct ntfs_super_block *ns;
struct master_file_table_record *mft;
struct file_attribute *attr;
- unsigned char label_str[129], *cp;
int bytes_per_sector, sectors_per_cluster;
int mft_record_size, attr_off, attr_len;
- unsigned int i, attr_type, val_len;
+ unsigned int attr_type, val_len;
int val_off;
uint64_t nr_clusters;
blkid_loff_t off;
@@ -128,7 +127,6 @@ static int probe_ntfs(blkid_probe pr, co
mft = (struct master_file_table_record *) buf_mft;
attr_off = le16_to_cpu(mft->attrs_offset);
- label_str[0] = 0;
while (1) {
attr = (struct file_attribute *) (buf_mft + attr_off);
@@ -147,16 +145,8 @@ static int probe_ntfs(blkid_probe pr, co
break;
if (attr_type == MFT_RECORD_ATTR_VOLUME_NAME) {
- if (val_len > sizeof(label_str))
- val_len = sizeof(label_str)-1;
-
- for (i=0, cp=label_str; i < val_len; i+=2,cp++) {
- val = ((uint8_t *) attr) + val_off + i;
- *cp = val[0];
- if (val[1])
- *cp = '?';
- }
- *cp = 0;
+ val = ((uint8_t *) attr) + val_off;
+ blkid_probe_set_utf8label(pr, val, val_len, BLKID_ENC_UTF16LE);
}
}
@@ -164,8 +154,6 @@ static int probe_ntfs(blkid_probe pr, co
(unsigned char *) &ns->volume_serial,
sizeof(ns->volume_serial),
"%016" PRIX64, le64_to_cpu(ns->volume_serial));
- if (label_str[0])
- blkid_probe_set_label(pr, label_str, strlen((char *)label_str));
return 0;
}
Index: util-linux-ng.spec
===================================================================
RCS file: /cvs/pkgs/rpms/util-linux-ng/F-12/util-linux-ng.spec,v
retrieving revision 1.65
retrieving revision 1.66
diff -u -p -r1.65 -r1.66
--- util-linux-ng.spec 7 Dec 2009 09:43:23 -0000 1.65
+++ util-linux-ng.spec 9 Dec 2009 20:58:54 -0000 1.66
@@ -2,7 +2,7 @@
Summary: A collection of basic system utilities
Name: util-linux-ng
Version: 2.16.2
-Release: 2%{?dist}
+Release: 3%{?dist}
License: GPLv2 and GPLv2+ and BSD with advertising and Public Domain
Group: System Environment/Base
URL: ftp://ftp.kernel.org/pub/linux/utils/util-linux-ng
@@ -106,9 +106,9 @@ Patch8: util-linux-ng-2.15-ipcs-32bit.pa
### Upstream patches
# 531992 - not prompted for passphrase
-Patch9: util-linux-ng-2.16-blkid-crypto.path
+Patch9: util-linux-ng-2.16-blkid-crypto.patch
# 536797 - ntfs volume labels are not correct in hal
-Patch10: util-linux-ng-2.16-blkid-ntfs.path
+Patch10: util-linux-ng-2.16-blkid-ntfs.patch
%description
The util-linux-ng package contains a large variety of low-level system
@@ -715,6 +715,9 @@ fi
%changelog
+* Wed Dec 9 2009 Karel Zak <kzak at redhat.com> 2.16.2-3
+- fix typo in spec file
+
* Mon Dec 7 2009 Karel Zak <kzak at redhat.com> 2.16.2-2
- fix #536797 - ntfs volume labels are not correct in hal
--- util-linux-ng-2.16-blkid-crypto.path DELETED ---
--- util-linux-ng-2.16-blkid-ntfs.path DELETED ---
More information about the fedora-extras-commits
mailing list