Bug 582929 - mknod doesn't check for invalid mode
Summary: mknod doesn't check for invalid mode
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libguestfs
Version: unspecified
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Richard W.M. Jones
QA Contact:
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-04-16 07:48 UTC by Yufang Zhang
Modified: 2010-05-21 00:31 UTC (History)
2 users (show)

(edit)
Clone Of:
(edit)
Last Closed: 2010-05-12 12:26:24 UTC


Attachments (Terms of Use)

Description Yufang Zhang 2010-04-16 07:48:34 UTC
Description of problem:
When create device file via mknod with invalid mode, it just succeeds but not reports any error. This is quite like the situation in BZ #582901.

Version-Release number of selected component (if applicable):
libguestfs-1.0.85-1.fc12.3.x86_64

How reproducible:
Always.

Steps to Reproduce:
1. ><fs> mknod-b 066666  8 1 /sd
mknod_b 28086 8 1 "/sd"
send_to_daemon: 0x25eb050 g->state = 3, n = 48
recv_from_daemon: 0x25eb050 g->state = 3, size_rtn = 0x7fffdb87b84c, buf_rtn = 0x7fffdb87b840
proc 135 (mknod_b) took 0.03 seconds

2. ><fs> ll /sd
ll "/sd"
send_to_daemon: 0x25eb050 g->state = 3, n = 36
recv_from_daemon: 0x25eb050 g->state = 3, size_rtn = 0x7fffdb87b86c, buf_rtn = 0x7fffdb87b860
ls -la /sysroot/sd
proc 5 (ll) took 0.00 seconds
brwSr-Sr-- 1 root root 8, 1 Apr 16 07:45 /sysroot/sd

3.
  
Actual results:


Expected results:
When you use a invalid mode, mknod should exit and report error.

Additional info:

Comment 2 Fedora Update System 2010-04-20 19:12:09 UTC
libguestfs-1.2.3-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/libguestfs-1.2.3-1.el5

Comment 3 Fedora Update System 2010-04-20 22:25:37 UTC
libguestfs-1.2.3-1.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/libguestfs-1.2.3-1.fc13

Comment 4 Fedora Update System 2010-04-21 12:42:28 UTC
libguestfs-1.2.3-1.fc12.6 has been submitted as an update for Fedora 12.
http://admin.fedoraproject.org/updates/libguestfs-1.2.3-1.fc12.6

Comment 5 Fedora Update System 2010-05-21 00:31:20 UTC
libguestfs-1.2.3-1.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.