Re: Cannot compile Squid3 fake_auth on Windows

From: Guido Serassio <guido.serassio_at_acmeconsulting.it>
Date: Wed, 09 Jul 2008 15:10:22 +0200

Hi Henrik,

At 00.45 09/07/2008, Henrik Nordstrom wrote:
>On tis, 2008-07-08 at 22:25 +0200, Guido Serassio wrote:
> > HI Amos,
> >
> > I'm trying to maintain up-to-date the Windows support even if it
> > doesn't run, so I have found a little build problem.
> >
> > This change broke fake_auth on Windows:
> > http://www.squid-cache.org/Versions/v3/HEAD/changesets/b8894.patch
> >
> > strtok_r() is not available on Windows. In the past there was an own
> > implementation of strtok_r(), but it was removed in favour of our
> > strwordtok():
> > http://www.squid-cache.org/Versions/v3/HEAD/changesets/11355.patch
> >
> > Any suggestion on how to replace the strtok_r() usage ?
>
>There is no need to strtok_r here..
>
> strtok(user, '\\');
> p = strtok(NULL, '\\');
>
>and also as an extra safeguard:
>
> if (!p)
> p = user;

Rigth, I was not thinking on the code .... :-(

Thanks

Regards

Guido

-
========================================================
Guido Serassio
Acme Consulting S.r.l. - Microsoft Certified Partner
Via Lucia Savarino, 1 10098 - Rivoli (TO) - ITALY
Tel. : +39.011.9530135 Fax. : +39.011.9781115
Email: guido.serassio_at_acmeconsulting.it
WWW: http://www.acmeconsulting.it/
Received on Wed Jul 09 2008 - 13:11:25 MDT

This archive was generated by hypermail 2.2.0 : Wed Jul 09 2008 - 12:00:04 MDT