LenToASCIIZStr

Converts a length-preceded string to an ASCIIZ (NULL-terminated)

Local Servers:nonblocking
Remote Servers:N/A
Classification:3.x, 4.x, 5.x, 6.x
Service:String Conversion

Syntax

  #include <nwstring.h>  
   
  int LenToASCIIZStr  (  
     char   *destStr,  
     char   *srcStr);
  

Parameters

destStr
(OUT) Points to the destination string.
srcStr
(IN) Points to the source string.

Return Values

The following table lists return values and descriptions.

Value

Name

Description

0

(0x00)

ESUCCESS

The srcStr is only copied up to the first NULL character or the length specified, whichever is shorter. If the string is not converted (due to a NULL being encountered), the value returned is the number of characters not copied to the destination string.

Remarks

LenToASCIIZStr call copies and converts a length-preceded string to an ASCIIZ (NULL-terminated) string.

The srcStr parameter is an ASCII string with the length of the string of the first byte and the actual characters of the string following it.

The srcStr can be the same as the destStr.