mirror of
https://git.savannah.gnu.org/git/coreutils.git
synced 2026-11-17 18:02:09 +03:00
(main): Check for NODEV device only if NODEV is defined.
This commit is contained in:
1 parent
b8b5b82220
commit
a8219ddccd
1 file changed
+2
@@ -186,8 +186,10 @@ numbers must be specified"));
|
||||
error (1, 0, _("invalid minor device number %s"), quote (s_minor));
|
||||
|
||||
device = makedev (i_major, i_minor);
|
||||
#ifdef NODEV
|
||||
if (device == NODEV)
|
||||
error (1, 0, _("invalid device %s %s"), s_major, s_minor);
|
||||
#endif
|
||||
|
||||
if (mknod (argv[optind], newmode | node_type, device) != 0)
|
||||
error (1, errno, "%s", quote (argv[optind]));
|
||||
|
||||
Reference in new issue
Block a user