diff options
author | David Hows <david.hows@mongodb.com> | 2016-06-24 17:05:13 +1000 |
---|---|---|
committer | David Hows <david.hows@mongodb.com> | 2016-06-24 17:05:13 +1000 |
commit | d8fb874fc40989cb9675e56ca80b3b64e6fa2ee3 (patch) | |
tree | 6f03ed5cde97aedc762215c14d23ee5305998a2b /dist/s_label | |
parent | fb1663e6fc800be97c0ddc697b6f939dc610e08e (diff) | |
parent | 1f4aaa4490a82cf947afdabbb9214ee5b1850d13 (diff) | |
download | mongodb-3.3.9.tar.gz |
Merge branch 'develop' of github.com:wiredtiger/wiredtiger into mongodb-3.4mongodb-3.3.9mongodb-3.3.10mongodb-3.0.1
Diffstat (limited to 'dist/s_label')
-rwxr-xr-x | dist/s_label | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/dist/s_label b/dist/s_label index b7c5795234a..b56ecc6fc78 100755 --- a/dist/s_label +++ b/dist/s_label @@ -23,7 +23,7 @@ file_parse() # where there's a jump to the error label after the error label. for f in `find bench examples ext src test -name '*.[ci]'`; do file_parse $f | - egrep '(WT_ERR|WT_ILLEGAL_VALUE_ERR)\(.*(WT_ILLEGAL_VALUE|WT_RET)\(.*err:|[^a-z_]err:.*(WT_ERR|WT_ILLEGAL_VALUE_ERR)\(' | + egrep '(WT_ERR[_A-Z]*|WT_ILLEGAL_VALUE_ERR)\(.*(WT_ILLEGAL_VALUE|WT_RET[_A-Z]*)\(.*err:|[^a-z_]err:.*(WT_ERR|WT_ILLEGAL_VALUE_ERR)\(' | sed 's/:.*//' > $t test -s $t && { @@ -32,6 +32,14 @@ for f in `find bench examples ext src test -name '*.[ci]'`; do } done +# Returns before jumps to an error label within the same loop. +# Jumps before returns have already been detected above. +for f in `find bench examples ext src test -name '*.[ci]'`; do + file_parse $f | sed "s=^=$f:=" +done | python dist/s_label_loop.py | + egrep '\{@[^@]*(WT_ILLEGAL_VALUE|WT_RET[_A-Z]*)\([^@]*(WT_ERR[_A-Z]*|WT_ILLEGAL_VALUE_ERR)\(.*err:' | + sed -e 's/^\([^:]*\): *\([^:]*\):.*/\1:\2: mix of returns and jump to the error label within a loop/' + # Return of 0 in functions after a jump to the error label. for f in `find bench examples ext src test -name '*.[ci]'`; do file_parse $f | |