mirror of
https://github.com/opnsense/src.git
synced 2026-04-20 21:59:20 -04:00
Move the redirection to stderr out of the cmd variable assignment
Putting 2>/dev/null in cmd= escapes the redirection operation, which causes mdconfig to think it's a filename MFC after: 2 weeks X-MFC with: r273627 Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
59dee1b08b
commit
fbb045e15e
1 changed files with 2 additions and 2 deletions
|
|
@ -167,8 +167,8 @@ create_memdisk()
|
|||
if [ -n "${devname}" ]; then
|
||||
devparam="-u ${devname}"
|
||||
fi
|
||||
cmd="mdconfig -a -t swap -s ${size} ${devparam} 2>/dev/null"
|
||||
DISKNAME=`${cmd}` || die "failed: ${cmd}"
|
||||
cmd="mdconfig -a -t swap -s ${size} ${devparam}"
|
||||
DISKNAME=`$cmd 2>/dev/null` || die "failed: ${cmd}"
|
||||
if [ -n "${devname}" ]; then
|
||||
DISKNAME="${devname}"
|
||||
fi
|
||||
|
|
|
|||
Loading…
Reference in a new issue