X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=extras%2Fvolume_id%2Fvolume_id%2Fntfs%2Fntfs.c;h=bf87f9d8d003b64c379e6e899118bab25e690100;hp=4e1f5085617d74154276426f0c4ebef9d0c1db69;hb=7979e3d4b7c56acee2fe0e9a9fefb3fe0d83771e;hpb=51df9ee4965516b17dcd50647546ee970df87b32;ds=inline diff --git a/extras/volume_id/volume_id/ntfs/ntfs.c b/extras/volume_id/volume_id/ntfs/ntfs.c index 4e1f50856..bf87f9d8d 100644 --- a/extras/volume_id/volume_id/ntfs/ntfs.c +++ b/extras/volume_id/volume_id/ntfs/ntfs.c @@ -122,7 +122,7 @@ int volume_id_probe_ntfs(struct volume_id *id, __u64 off) if (ns == NULL) return -1; - if (strncmp(ns->oem_id, "NTFS", 4) != 0) + if (memcmp(ns->oem_id, "NTFS", 4) != 0) return -1; volume_id_set_uuid(id, ns->volume_serial, UUID_NTFS); @@ -153,7 +153,7 @@ int volume_id_probe_ntfs(struct volume_id *id, __u64 off) mftr = (struct master_file_table_record*) buf; dbg("mftr->magic '%c%c%c%c'", mftr->magic[0], mftr->magic[1], mftr->magic[2], mftr->magic[3]); - if (strncmp(mftr->magic, "FILE", 4) != 0) + if (memcmp(mftr->magic, "FILE", 4) != 0) goto found; attr_off = le16_to_cpu(mftr->attrs_offset);