Thanks, David.  This is essentially the same fix as the aixxlc.0 patch in
the archives.  It looks like there's more than one non-GNU C++ compiler
that doesn't like variable declarations within a while loop, so we should
probably try to avoid this sort of thing in the future.

According to Graff, David:
> The included patch allows for compilation of htdig under Sparc C 4.2.  It is
> simply a pre-declaration of a variable in a while loop in the file
> htdig/Retriever.cc
> 
> =============================================
> --- htdig-3.1.5/htdig/Retriever.cc      Thu Feb 24 21:29:10 2000
> +++ htdig-3.1.5.sparc/htdig/Retriever.cc        Thu Apr 19 17:34:20 2001
> @@ -837,7 +837,8 @@ Retriever::GetLocal(char *url)
>             *local += &url[prefix->length()];
>             if (local->last() == '/' && defaultdocs) {
>               defaultdocs->Start_Get();
> -             while (String *defaultdoc = (String *)defaultdocs->Get_Next())
> {
> +              String *defaultdoc= NULL;
> +             while (defaultdoc = (String *)defaultdocs->Get_Next()) {
>                 String *localdefault = new String(*local,
> local->length()+defaul
> tdoc->length()+1);
>                 localdefault->append(*defaultdoc);
>                 local_names->Add(localdefault);
> @@ -964,7 +965,8 @@ Retriever::GetLocalUser(char *url, Strin
>         *local += rest;
>         if (local->last() == '/' && defaultdocs) {
>           defaultdocs->Start_Get();
> -         while (String *defaultdoc = (String *)defaultdocs->Get_Next()) {
> +          String *defaultdoc= NULL;
> +         while (defaultdoc = (String *)defaultdocs->Get_Next()) {
>             String *localdefault = new String(*local,
> local->length()+defaultdoc
> ->length()+1);
>             localdefault->append(*defaultdoc);
>  
> local_names->Add(localdefault);=============================================


-- 
Gilles R. Detillieux              E-mail: <[EMAIL PROTECTED]>
Spinal Cord Research Centre       WWW:    http://www.scrc.umanitoba.ca/~grdetil
Dept. Physiology, U. of Manitoba  Phone:  (204)789-3766
Winnipeg, MB  R3E 3J7  (Canada)   Fax:    (204)789-3930

_______________________________________________
htdig-general mailing list <[EMAIL PROTECTED]>
To unsubscribe, send a message to <[EMAIL PROTECTED]> with a 
subject of unsubscribe
FAQ: http://htdig.sourceforge.net/FAQ.html

Reply via email to