[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
re: new nsallinone version
Did you try to build a debug version of ns and use a debugger to see where
the segv happens? If my guess is correct, it happens in trace.cc,
Trace::format() and DequeueTrace::recv(). Check for "sname" in those
functions, and change the following lines:
if (strcmp(name,"SRM") == 0 || strcmp(name,"cbr") == 0) {
if ( sh->type() < 5 && sh->type() >=0 ) {
sname = srm_names[sh->type()];
}
}
to:
if (strcmp(name,"SRM") == 0 || strcmp(name,"cbr") == 0) {
if ( sh->type() < 5 && sh->type() >=0 ) {
sname = srm_names[sh->type()];
}
} else
sname = "null";
The previous problem is, sname is assigned to 0 and sprintf tries to get a
string out of it.
Let me know if it works.
- Haobo
On Thu, 16 Jul 1998, Hugh Smith wrote:
> I'm still having trouble with version 2.1b3 and the allinone
> installation. I get a segfault when I try to run simulations on
> the tutorial examples or the file tcl/ex/simple-dyn.tcl.
>
> The segfault goes away if I comment out the line:
>
> $ns namtrace-all $nf
>
>
> The steps I have taken are:
>
> 1) Reinstalled the allinone version. (This cleared up the problem
> of xgraph not compiling.)
>
> 2) I checked that my LD_LIBRARY_PATH was correct (it was).
>
> 3) Just in case I did the cd octl; make. This worked ok but did not
> clear up the problem.
>
> Thoughts?
>
> Also, is there any documentation on the changes talked about in Ya
> Xu's message regarding version v2.1b3.
>
> Thanks, Hugh
>