summaryrefslogtreecommitdiffstats
path: root/277/regr/testcase
diff options
context:
space:
mode:
Diffstat (limited to '277/regr/testcase')
-rwxr-xr-x277/regr/testcase33
1 files changed, 33 insertions, 0 deletions
diff --git a/277/regr/testcase b/277/regr/testcase
new file mode 100755
index 0000000..10ad25a
--- /dev/null
+++ b/277/regr/testcase
@@ -0,0 +1,33 @@
+#!/bin/bash
+
+description="# fcntl system with F_DUPFD command fails on booster"
+comments="# when fcntl system call is executed with the F_DUPFD command the call fails with EINVAL as the error status"
+
+source ../../init
+
+start_glusterfs --no-clients
+
+sleep 5
+
+echo "$SPECDIR/client1.vol $MOUNTDIR/client1 glusterfs subvolume=client,logfile=$LOGDIR/clog,loglevel=DEBUG" > $SPECDIR/booster.conf
+export GLUSTERFS_BOOSTER_FSTAB=$SPECDIR/booster.conf
+export LD_PRELOAD=$(dirname $GLUSTERFSDIR)/lib/glusterfs/glusterfs-booster.so
+touch $MOUNTDIR/client1/a1
+
+sleep 2
+gcc $SPECDIR/fcntl.c -o $SPECDIR/fcntl
+$SPECDIR/fcntl $MOUNTDIR/client1/a1
+
+if [ $? -eq 22 ]; then
+ not_ok $description
+ comment $comments
+else
+ ok $description
+ comment $comments
+fi
+
+rm $SPECDIR/fcntl $SPECDIR/booster.conf
+GLUSTERFS_BOOSTER_FSTAB=
+LD_PRELOAD=
+
+cleanup_glusterfs \ No newline at end of file