On Mon, 2008-05-12 at 18:41 +0000, Sasha Khapyorsky wrote: > On 14:01 Sun 04 May , Hal Rosenstock wrote: > > ibsim/sim.h: Fix NodeDescription size so can have maximum size > > NodeDescription per IBA spec rather than truncating them > > > > Signed-off-by: Hal Rosenstock <[EMAIL PROTECTED]> > > > > diff --git a/ibsim/sim.h b/ibsim/sim.h > > index bea136a..dbf1220 100644 > > --- a/ibsim/sim.h > > +++ b/ibsim/sim.h > > @@ -67,7 +67,7 @@ > > > > #define NODEIDBASE 20 > > #define NODEPREFIX 20 > > -#define NODEIDLEN (NODEIDBASE+NODEPREFIX+1) > > +#define NODEIDLEN 65 > > #define ALIASLEN 40 > > nodeid filed in struct Node still have length 64, so it looks that using > NODEIDLEN value larger than this introduces overflow. I think bigger > change is needed there.
I made NODEIDLEN 65 rather than 64 due to the +1 in the original define. How about defining it as 64 as in the below ? Does that get around the overflow issue ? -- Hal ibsim/sim.h: Fix NodeDescription size so can have maximum size NodeDescription per IBA spec rather than truncating them Signed-off-by: Hal Rosenstock <[EMAIL PROTECTED]> diff --git a/ibsim/sim.h b/ibsim/sim.h index bea136a..0bf14fd 100644 --- a/ibsim/sim.h +++ b/ibsim/sim.h @@ -65,9 +65,8 @@ #define DEFAULT_LINKWIDTH LINKWIDTH_4x #define DEFAULT_LINKSPEED LINKSPEED_SDR -#define NODEIDBASE 20 #define NODEPREFIX 20 -#define NODEIDLEN (NODEIDBASE+NODEPREFIX+1) +#define NODEIDLEN 64 #define ALIASLEN 40 #define MAXHOPS 16 > Sasha _______________________________________________ general mailing list [email protected] http://lists.openfabrics.org/cgi-bin/mailman/listinfo/general To unsubscribe, please visit http://openib.org/mailman/listinfo/openib-general
