From: Martin Quinson Date: Mon, 7 Mar 2016 20:28:09 +0000 (+0100) Subject: kill an obsolete script X-Git-Tag: v3_13~497 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/84ef1bcfaab825a6b2d432bc4026ed0edac29c50 kill an obsolete script --- diff --git a/include/xbt/ex.h b/include/xbt/ex.h index 54a55f3483..8ca0a18447 100644 --- a/include/xbt/ex.h +++ b/include/xbt/ex.h @@ -177,12 +177,8 @@ __ex_mctx_struct} __ex_mctx_t; * cleanup that needs to be done regardless of whether an exception is * caught. Bypassing these steps will break the exception handling facility. * The symptom are likely to be a segfault at the next exception raising point, - * ie far away from the point where you did the mistake. If you suspect - * that kind of error in your code, have a look at the little script - * tools/xbt_exception_checker in the CVS. It extracts all the TRY - * blocks from a set of C files you give it and display them (and only - * them) on the standard output. You can then grep for the forbidden - * keywords on that output. + * ie far away from the point where you did the mistake. Finding the problem can + * reveal challenging, unfortunately. * * The CLEANUP and CATCH blocks are regular ISO-C language statement * blocks without any restrictions. You are even allowed to throw (and, in the diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt index 002deb0c54..dc0373071b 100644 --- a/tools/CMakeLists.txt +++ b/tools/CMakeLists.txt @@ -7,7 +7,6 @@ set(bin_files ${CMAKE_CURRENT_SOURCE_DIR}/sg_unit_extractor.pl ${CMAKE_CURRENT_SOURCE_DIR}/sg_xml_unit_converter.py ${CMAKE_CURRENT_SOURCE_DIR}/simgrid_update_xml.pl - ${CMAKE_CURRENT_SOURCE_DIR}/xbt_exception_checker ${CMAKE_CURRENT_SOURCE_DIR}/doxygen/fig2dev_postprocessor.pl ${CMAKE_CURRENT_SOURCE_DIR}/doxygen/index_create.pl ${CMAKE_CURRENT_SOURCE_DIR}/doxygen/xbt_log_extract_hierarchy.pl diff --git a/tools/xbt_exception_checker b/tools/xbt_exception_checker deleted file mode 100755 index 3ebadcca72..0000000000 --- a/tools/xbt_exception_checker +++ /dev/null @@ -1,43 +0,0 @@ -#! /bin/bash - -# This little script parse a list of C files, and extract the TRY blocks of it. -# Martin Quinson, 2006. -# Demerdierensiesich licence. - -# It can reveal usefull when you have a segfault on exception throwing. This -# is often the symptom that something somewhere got out of a TRY block with -# return, goto, break or such. This is forbiden because some extra cleanups -# must be performed at the end of the block. - -# So, if it happens to you, you may find this script usefull: let it extract -# all the TRY blocks of your project, and grep for the forbidden keywords -# given above. - -# You obviously have to adapt it to your case. The proper solution would be -# to accept the extra -I pathes from the command line. -# Patch welcome ;) - -for file in `find -name '*.c'` ; do - -base=`dirname $file` -cmd="cat $file \ - | cpp -I/home/mquinson/CVSIMPORT/gras/gras/include \ - -I/home/mquinson/CVSIMPORT/gras/gras/src \ - -I/home/mquinson/CVSIMPORT/gras/gras/src/include \ - -I$base \ - -D__XBT_EX_H__ -D_XBT_LOG_H_ \ - | sed -n -e '/TRY/,/CATCH/p' \ - | sed -e 's/^.*TRY.*$/----------------/' -e '/CATCH/d'" - -err=`eval $cmd 2>&1 >/dev/null` -if [ -n "$err" ] ; then - echo "XXXXXXXXXX ERROR IN FILE $file" - echo $err -fi - -if [ -n "`eval $cmd 2>/dev/null`" ] ; then - echo "XXX FILE $file" - eval "$cmd" 2>/dev/null -fi - -done