Am Donnerstag, den 21.08.2008, 17:35 -0500 schrieb John Klehm:
> On Thu, Aug 21, 2008 at 4:35 PM, Michael Karcher
> <[EMAIL PROTECTED]> wrote:
> > page, stating that
> >  lstrcpyn(dest,"abcdefghi",4)
> > puts "abc" into dest.
> Seems like Wine's version at least always null terminates it, so
> "abc\0".
Sorry if my words were unclear. With "abc" I meant the C language string
consisting of the letters 'a', 'b' and 'c', which by definition also has
a terminating NUL byte. lstrcpyn does *always* zero terminate the string
if the memory is accessible. According to MSDN it catches write faults
using SEH, and returns an error code. Only in this case the output could
be unterminated.

Regards,
  Michael Karcher




Reply via email to