Skip to content

Commit 43b3ee9

Browse files
cryptomilkvlendec
authored andcommitted
s3:tests: Use bash and disable history expansion for test_wbinfo_lookuprids_cache.sh
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Tue Aug 5 12:50:07 UTC 2025 on atb-devel-224
1 parent df35b10 commit 43b3ee9

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

source3/script/tests/test_wbinfo_lookuprids_cache.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
#!/bin/sh
1+
#!/bin/bash
2+
3+
# Disabling history expansion temporarily
4+
# This is needed, as the tdb key can include e.g. !6
5+
set +H
26

37
WBINFO="$VALGRIND ${WBINFO:-$BINDIR/wbinfo}"
48
samba_tdbtool=tdbtool
@@ -26,7 +30,7 @@ testit "lookuprids1" "$WBINFO" "-R" "512,12345" || failed=$(expr $failed + 1)
2630
opnum=$($PYTHON -c'from samba.dcerpc.winbind import wbint_LookupRids; print(wbint_LookupRids.opnum())')
2731
key=$("$TDBDUMP" "$cache" | awk -F'"' -v opnum="${opnum}" '/key.*NDR/ { regex = "NDR/[^/]+/" opnum "/.*$"; if (match($2, regex)) print substr($2, RSTART, RLENGTH) }')
2832

29-
testit "delete" "$TDBTOOL" "$cache" delete "$key"
33+
testit "delete key" "$TDBTOOL" "$cache" delete "$key" || failed=$((failed + 1))
3034
testit "lookuprids2" "$WBINFO" "-R" "512,12345" || failed=$(expr $failed + 1)
3135

3236
testok $0 $failed

0 commit comments

Comments
 (0)