Group :: System/Kernel and hardware
RPM: fstyp
Main Changelog Spec Patches Sources Download Gear Bugs and FR Repocop
Patch: fstyp-file.patch
Download
Download
diff -ur fstyp-0.1-orig/src/mount_guess_fstype.c fstyp-0.1/src/mount_guess_fstype.c
--- fstyp-0.1-orig/src/mount_guess_fstype.c 2001-11-19 08:53:45 +0300
+++ fstyp-0.1/src/mount_guess_fstype.c 2003-11-06 15:23:53 +0300
@@ -174,8 +174,8 @@
/* opening and reading an arbitrary unknown path can have
undesired side effects - first check that `device' refers
- to a block device */
- if (stat (device, &statbuf) || !S_ISBLK(statbuf.st_mode))
+ to a block device or regular file */
+ if (stat (device, &statbuf) || (!S_ISBLK(statbuf.st_mode) && !S_ISREG(statbuf.st_mode)))
return 0;
fd = open(device, O_RDONLY);