Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37733629
en ru br
ALT Linux repos
S:0.1-alt7.qa1
5.0: 0.1-alt6
4.1: 0.1-alt5
4.0: 0.1-alt5
3.0: 0.1-alt5

Group :: System/Kernel and hardware
RPM: fstyp

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Patch: fstyp-file.patch
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);
 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin