Initial bugs in mktop and top2dot

ML ml at kenweb.org
Sun Feb 15 03:13:59 UTC 2009


I just read Joe Abley and Stephen Stuart's paper titled: "Managing IP 
Networks
with Free Software"

I found two bugs so far with the scripts. One in mktop.awk and one in 
top2dot.awk

For unknown reasons by awk interpreter refused to parse mktop.awk with 
the comments present
on lines:  329, 338, 347, 356, 444

Script out:
----------------
awk: ./mktop.awk: line 329: regular expression compile failed (missing 
operand)
* hack hack *
awk: ./mktop.awk: line 338: regular expression compile failed (missing 
operand)
* hack hack *
awk: ./mktop.awk: line 347: regular expression compile failed (missing 
operand)
* hack hack *
awk: ./mktop.awk: line 356: regular expression compile failed (missing 
operand)
* hack hack *
awk: ./mktop.awk: line 444: regular expression compile failed (missing 
operand)
* undirected graph *
----------------

Removing the comments allows the script to finish successfully.

I'll chalk it up to a difference in the awk interepreter between 2002 
and 2009.

After running converting a generated top file to a dot file (using 
top2dot), the resulting dot file contains
a spurious backslash on the last line of the file which causes 'dot' to 
fail. Removing the erroneous
backslash allows 'dot' to process the generated .dot file.








More information about the Toolmakers mailing list