Re: [htdig] [Again] Pb accessing docdb from Perl contribs


Geoff Hutchison (ghutchis@wso.williams.edu)
Thu, 4 Feb 1999 11:31:08 -0500 (EST)


On 4 Feb 1999, heddy Boubaker wrote:

> The parse_ref_record function is the same in all these scripts and it seems
> buggy, I do not know the internals of htdig dbs

Alas, they have not kept up with the additional fields in the databases.
Here's an untested patch. I think it should solve the problem:

Index: whatsnew.pl
===================================================================
RCS file: /opt/htdig/cvs/htdig3/contrib/whatsnew/whatsnew.pl,v
retrieving revision 1.3
diff -r1.3 whatsnew.pl
334a335,360
> elsif ($what == 16)
> {
> # STRING (ignore, but unpack)
> $length = unpack("i", $value);
> $rec{"STRING"} = unpack("x4 A$length", $value);
> $value = substr($value, 4 + $length);
> }
> elsif ($what == 17)
> {
> # METADSC
> $length = unpack("i", $value);
> $rec{"METADSC"} = unpack("x4 A$length", $value);
> $value = substr($value, 4 + $length);
> }
> elsif ($what == 18)
> {
> # BACKLINKS
> $rec{"BACKLINKS"} = unpack("i", $value);
> $value = substr($value, 4);
> }
> elsif ($what == 19)
> {
> # SIGNATURE
> $rec{"SIG"} = unpack("i", $value);
> $value = substr($value, 4);
> }

-Geoff Hutchison
Williams Students Online
http://wso.williams.edu/

------------------------------------
To unsubscribe from the htdig mailing list, send a message to
htdig@htdig.org containing the single word "unsubscribe" in
the SUBJECT of the message.



This archive was generated by hypermail 2.0b3 on Wed Feb 10 1999 - 17:09:05 PST