aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>2006-04-19 10:21:55 +0000
committerguy <guy@f5534014-38df-0310-8fa8-9805f1628bb7>2006-04-19 10:21:55 +0000
commite6fa97914ba74414ac59e6955d7675b9aaf514d6 (patch)
tree3ffbe205ce26d938688ac3455e5a4d101ec068e1 /tools
parentde2b7a81688963d567f5373d8fe84383ba1cf446 (diff)
Fix bugs in the previous checkin.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@17905 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'tools')
-rwxr-xr-xtools/make-reg-dotc6
1 files changed, 6 insertions, 0 deletions
diff --git a/tools/make-reg-dotc b/tools/make-reg-dotc
index b1b57e0ce2..19706dada5 100755
--- a/tools/make-reg-dotc
+++ b/tools/make-reg-dotc
@@ -21,6 +21,7 @@ if [ "$registertype" = plugin ]
then
outfile="plugin.c"
elif [ "$registertype" = dissectors ]
+then
outfile="register.c"
else
echo "Unknown output type '$registertype'" 1>&2
@@ -104,6 +105,7 @@ void
register_all_protocol_handoffs(void)
{
EOF
+fi
for f in "$@"
do
if [ -f $f ]
@@ -125,4 +127,8 @@ do
grep '^void proto_reg_handoff_[a-z_0-9A-Z]* *(' $srcfile 2>/dev/null | grep -v ';'
done | sed -e 's/^.*://' -e 's/^void \([a-z_0-9A-Z]*\).*/ {extern void \1 (void); \1 ();}/' >>${outfile}-tmp
echo '}' >>${outfile}-tmp
+if [ "$registertype" = plugin ]
+then
+ echo '#endif' >>${outfile}-tmp
+fi
mv ${outfile}-tmp ${outfile}