delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/07/11/12:10:37

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Mon, 11 Jul 2005 12:10:03 -0400 (EDT)
From: Igor Pechtchanski <pechtcha AT cs DOT nyu DOT edu>
Reply-To: cygwin AT cygwin DOT com
To: Dave Korn <dave DOT korn AT artimi DOT com>
cc: cygwin AT cygwin DOT com
Subject: RE: Inconsistent behavior for Win32 executable: starting from bash vs. starting from cmd.exe
In-Reply-To: <SERRANO1YBTUA93Nii500000490@SERRANO.CAM.ARTIMI.COM>
Message-ID: <Pine.GSO.4.61.0507111208520.7597@slinky.cs.nyu.edu>
References: <SERRANO1YBTUA93Nii500000490 AT SERRANO DOT CAM DOT ARTIMI DOT COM>
MIME-Version: 1.0

On Mon, 11 Jul 2005, Dave Korn wrote:

> ----Original Message----
> >From: Igor Pechtchanski
> >Sent: 11 July 2005 16:26
>
> > Would
> >
> > UNIVERSAL_NAME_INFO szBuff;
> > UNIVERSAL_NAME_INFO *puni = &szBuff;
> >
> > work better?  I'm not familiar with UNIVERSAL_NAME_INFO, but the above
> > assumes it's no larger than 2k in size.
>
>   No it doesn't.  Check cbBuff.

Yes, it does.  I'm not saying it'll write over 2k into the struct, I'm
saying the WNetGetUniversalName call may return a weird error if it's
unable to completely fill in the struct.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha AT cs DOT nyu DOT edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor AT watson DOT ibm DOT com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

If there's any real truth it's that the entire multidimensional infinity
of the Universe is almost certainly being run by a bunch of maniacs. /DA

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019