- Fix failing mmap calls in mkcramfs by correctly defining a constant.
- Call mkfifo instead of mknod for creating FIFOs to fix cramfsck. PR: 116292 Submitted by: Christopher Hall <freebsd@generalresources.com> Approved by: maintainer
This commit is contained in:
parent
da67700292
commit
fb94e060a6
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=200055
3 changed files with 22 additions and 1 deletions
|
@ -7,6 +7,7 @@
|
|||
|
||||
PORTNAME= cramfs
|
||||
PORTVERSION= 1.1
|
||||
PORTREVISION= 1
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= SOURCEFORGE
|
||||
MASTER_SITE_SUBDIR= cramfs
|
||||
|
|
|
@ -17,3 +17,23 @@
|
|||
|
||||
/* Exit codes used by fsck-type programs */
|
||||
#define FSCK_OK 0 /* No errors */
|
||||
@@ -603,8 +603,17 @@
|
||||
}
|
||||
|
||||
if (opt_extract) {
|
||||
- if (mknod(path, i->mode, devtype) < 0) {
|
||||
- die(FSCK_ERROR, 1, "mknod failed: %s", path);
|
||||
+ switch(type) {
|
||||
+ default:
|
||||
+ if (mknod(path, i->mode, devtype) < 0) {
|
||||
+ die(FSCK_ERROR, 1, "mknod failed: %s", path);
|
||||
+ }
|
||||
+ break;
|
||||
+ case 'p':
|
||||
+ if (mkfifo(path, i->mode) < 0) {
|
||||
+ die(FSCK_ERROR, 1, "mkfifo failed: %s", path);
|
||||
+ }
|
||||
+ break;
|
||||
}
|
||||
change_file_status(path, i);
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
#include <linux/cramfs_fs.h>
|
||||
#include <zlib.h>
|
||||
|
||||
+#define MAP_ANONYMOUS 0x20
|
||||
+#define MAP_ANONYMOUS MAP_ANON
|
||||
+typedef long long loff_t;
|
||||
+
|
||||
/* Exit codes used by mkfs-type programs */
|
||||
|
|
Loading…
Reference in a new issue