Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 15 21:55, Brian Dessent wrote: Corinna Vinschen wrote: I just found that, regardless of my privileges, setup-1.7 defaults to install for just me instead of all users while the standard setup defaults to all users. Why does that happen? This is very odd. Setup's is_admin() was

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Brian Dessent
Corinna Vinschen wrote: Not really, no. 1024 bytes should be big enough in most cases. Did you look for the desired size which now gets returned by the NULL call? Yes, it was in the neighborhood of 230 bytes or so. It wasn't that the buffer was too small, and I would have expected

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 16 02:12, Brian Dessent wrote: Corinna Vinschen wrote: Not really, no. 1024 bytes should be big enough in most cases. Did you look for the desired size which now gets returned by the NULL call? Yes, it was in the neighborhood of 230 bytes or so. It wasn't that the buffer was

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 16 11:28, Corinna Vinschen wrote: On Apr 16 02:12, Brian Dessent wrote: Corinna Vinschen wrote: Not really, no. 1024 bytes should be big enough in most cases. Did you look for the desired size which now gets returned by the NULL call? Yes, it was in the neighborhood of

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 16 02:45, Brian Dessent wrote: Corinna Vinschen wrote: Alignment? Perhaps. Do you know if gcc aligns VLAs higher than their natural alignment? The nonworking code was just UCHAR foo[1024] whereas the working was char buf[size], which I cribbed from grp.cc:internal_getgroups().

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Brian Dessent
Corinna Vinschen wrote: Alignment? Perhaps. Do you know if gcc aligns VLAs higher than their natural alignment? The nonworking code was just UCHAR foo[1024] whereas the working was char buf[size], which I cribbed from grp.cc:internal_getgroups(). Brian

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 16 02:49, Brian Dessent wrote: Don't you love discovering these little pearls of joy inside the Win32 API? They're like little rays of sunshine. No wait, the opposite. Big rays of moonshine? ;) Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Brian Dessent
Corinna Vinschen wrote: I mean, token_info was an UCHAR array, so it's not aligned while the token_group information might require a 4 or 8 byte alignment which you now get by chance. Probably you'd be better off not using `char buf[size]' but PTOKEN_GROUPS groups = (PTOKEN_GROUPS)

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Corinna Vinschen
On Apr 16 02:45, Brian Dessent wrote: Corinna Vinschen wrote: Alignment? Perhaps. Do you know if gcc aligns VLAs higher than their natural alignment? The nonworking code was just UCHAR foo[1024] whereas the working was char buf[size], which I cribbed from grp.cc:internal_getgroups().

Re: setup-1.7 defaults to Just me

2008-04-16 Thread Christopher Faylor
On Wed, Apr 16, 2008 at 02:49:33AM -0700, Brian Dessent wrote: Don't you love discovering these little pearls of joy inside the Win32 API? They're like little rays of sunshine. No wait, the opposite. Windoze rulez! cgf

setup-1.7 defaults to Just me

2008-04-15 Thread Corinna Vinschen
Brian, I just found that, regardless of my privileges, setup-1.7 defaults to install for just me instead of all users while the standard setup defaults to all users. Why does that happen? Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Project

Re: setup-1.7 defaults to Just me

2008-04-15 Thread Brian Dessent
Corinna Vinschen wrote: I just found that, regardless of my privileges, setup-1.7 defaults to install for just me instead of all users while the standard setup defaults to all users. Why does that happen? This is very odd. Setup's is_admin() was returning 0 despite the user belonging to the