File tree Expand file tree Collapse file tree 11 files changed +18
-15
lines changed Expand file tree Collapse file tree 11 files changed +18
-15
lines changed Original file line number Diff line number Diff line change 4949}
5050
5151rm -f $PREFIX /largefile
52- dd if=/dev/zero of=$PREFIX /largefile seek=$(( 20 * 1024 * 1024 )) count=1 bs=1
52+ LD_PRELOAD= ' ' dd if=/dev/zero of=$PREFIX /largefile seek=$(( 20 * 1024 * 1024 )) count=1 bs=1
5353
5454incdir=$( dirname $0 ) /../../../testprogs/blackbox
5555. $incdir /subunit.sh
Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ create_test_data()
5858 if have_command " od" ; then # Use random file sizes
5959 local RND_COUNT
6060 for RND_COUNT in $( od -An -N$NUM_FILES -tu1 < /dev/urandom) ; do
61- if ! dd if=/dev/urandom of=" $DIR /file.$I " bs=$BS count=$RND_COUNT > /dev/null 2>&1 ; then
61+ if ! LD_PRELOAD= ' ' dd if=/dev/urandom of=" $DIR /file.$I " bs=$BS count=$RND_COUNT > /dev/null 2>&1 ; then
6262 echo " Couldn't create test file '$DIR /file.$I ' (random size)"
6363 false
6464 return
@@ -67,7 +67,7 @@ create_test_data()
6767 done
6868 else # Fallback to same file sizes
6969 while [ $I -le $NUM_FILES ]; do
70- if ! dd if=/dev/urandom of=" $DIR /file.$I " bs=$BS count=$NORND_COUNT > /dev/null 2>&1 ; then
70+ if ! LD_PRELOAD= ' ' dd if=/dev/urandom of=" $DIR /file.$I " bs=$BS count=$NORND_COUNT > /dev/null 2>&1 ; then
7171 echo " Couldn't create test file '$DIR /file.$I ' (static size)"
7272 false
7373 return
Original file line number Diff line number Diff line change @@ -34,12 +34,13 @@ samba_texpect="${BINDIR}/texpect"
3434create_test_data ()
3535{
3636 pushd $WORKDIR
37- dd if=/dev/urandom bs=1024 count=128 of=testfile
37+ # Do not preload anything for dd
38+ LD_PRELOAD=' ' dd if=/dev/urandom bs=1024 count=128 of=testfile
3839 chmod 644 testfile
3940 mkdir dir1
40- dd if=/dev/urandom bs=1024 count=128 of=dir1/testfile1
41+ LD_PRELOAD= ' ' dd if=/dev/urandom bs=1024 count=128 of=dir1/testfile1
4142 mkdir dir2
42- dd if=/dev/urandom bs=1024 count=128 of=dir2/testfile2
43+ LD_PRELOAD= ' ' dd if=/dev/urandom bs=1024 count=128 of=dir2/testfile2
4344 popd
4445}
4546
@@ -308,7 +309,8 @@ test_resume()
308309test_resume_modified ()
309310{
310311 clear_download_area
311- dd if=/dev/urandom bs=1024 count=2 of=testfile
312+ # Do not preload anything for dd
313+ LD_PRELOAD=' ' dd if=/dev/urandom bs=1024 count=2 of=testfile
312314 $SMBGET --verbose --resume -U${SERVER} /${USERNAME} %$PASSWORD smb://$SERVER_IP /smbget/testfile
313315 if [ $? -ne 1 ]; then
314316 echo ' ERROR: RC does not match, expected: 1'
Original file line number Diff line number Diff line change @@ -26,7 +26,8 @@ TESTDIR=$LOCAL_PATH/zero_data
2626mkdir -p $TESTDIR
2727chmod 777 p $TESTDIR
2828
29- dd if=/dev/urandom of=$TESTDIR /testfile bs=1024 count=128
29+ # Do not preload anything for dd
30+ LD_PRELOAD=' ' dd if=/dev/urandom of=$TESTDIR /testfile bs=1024 count=128
3031chmod 777 $TESTDIR /testfile
3132
3233alloc_kb=$( du -k $TESTDIR /testfile | sed -e ' s/\t.*//' )
Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ do_setup()
4040{
4141 rm -f " ${PREFIX} /zero_read_testfile"
4242 rm -f " ${PREFIX} /zero_read_testfile_get"
43- dd if=/dev/zero of=" ${PREFIX} /zero_read_testfile" bs=1024 count=1
43+ LD_PRELOAD= ' ' dd if=/dev/zero of=" ${PREFIX} /zero_read_testfile" bs=1024 count=1
4444 global_inject_conf=" $( dirname " ${SERVERCONFFILE} " ) /global_inject.conf"
4545 echo " smb2 max read = 0" > " $global_inject_conf "
4646 ${SMBCONTROL} ${CONF} smbd reload-config
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ destfile=tempfile.dst.$$
4242destpath=${SELFTEST_TMPDIR} /$destfile
4343
4444# Create a source file with arbitrary contents
45- dd if=$DD of=$sourcepath bs=1024 count=50 > /dev/null
45+ LD_PRELOAD= ' ' dd if=$DD of=$sourcepath bs=1024 count=50 > /dev/null
4646
4747ls -l $sourcepath
4848
Original file line number Diff line number Diff line change 3030 exit 0
3131fi
3232
33- HOSTNAME=$( dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
33+ HOSTNAME=$( LD_PRELOAD= ' ' dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
3434
3535RUNDIR=$( pwd)
3636cd $BASEDIR
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ DC_USERNAME=$2
1010DC_PASSWORD=$3
1111BASEDIR=$4
1212
13- HOSTNAME=$( dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
13+ HOSTNAME=$( LD_PRELOAD= ' ' dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
1414
1515RUNDIR=$( pwd)
1616cd $BASEDIR
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ DC_USERNAME=$2
1010DC_PASSWORD=$3
1111BASEDIR=$4
1212
13- HOSTNAME=$( dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
13+ HOSTNAME=$( LD_PRELOAD= ' ' dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
1414
1515RUNDIR=$( pwd)
1616cd $BASEDIR
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ DC_USERNAME=$2
1010DC_PASSWORD=$3
1111BASEDIR=$4
1212
13- HOSTNAME=$( dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
13+ HOSTNAME=$( LD_PRELOAD= ' ' dd if=/dev/urandom bs=1 count=32 2> /dev/null | sha1sum | cut -b 1-10)
1414
1515RUNDIR=$( pwd)
1616cd $BASEDIR
You can’t perform that action at this time.
0 commit comments