Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#24 example code error in document

open
nobody
None
5
2009-03-20
2009-03-20
Anonymous
No

http://judy.sourceforge.net/doc/JudyHS_3x.htm

if (*PValue == 0) // check if duplicate
{
Dups++;
printf("Duplicate lines %lu:%lu:%s", *PValue, LineNumb, Index);
}
else
{
*PValue = LineNumb; // store Line number
}

should be:

if (*PValue == 0) // check if duplicate
{
*PValue = LineNumb; // store Line number
}
else
{
Dups++;
printf("Duplicate lines %lu:%lu:%s", *PValue, LineNumb, Index);
}

Discussion

  • Jeff Norden
    Jeff Norden
    2010-11-04

    I just discovered this, and was about to post a bug. If / when there is a new release, *please* fix the code for this example. The error also appears in the JudyHS man page.

    Thanks!
    -Jeff