NSAPI Functions (in Alphabetical Order)
Chapter
5
NSAPI Function Reference
201
util_sh_escape
The
util_sh_escape
function parses a specified string and places a backslash (
\
)
in front of any shell-special characters, returning the resultant string. Use this
function to ensure that strings from clients won’t cause a shell to do anything
unexpected.
The shell-special characters are the space plus the following characters:
&;`'"|*?~<>^()[]{}$\#!
Syntax
char *util_sh_escape(char *s);
Returns
A newly allocated string
Parameters
char *s
is the string to be parsed.
See also
util_uri_escape
util_snprintf
The
util_snprintf
function formats a specified string, using a specified format,
into a specified buffer using the
printf
-style syntax and performs bounds
checking. It returns the number of characters in the formatted buffer.
For more information, see the documentation on the
printf
function for the
run-time library of your compiler.
Syntax
int util_snprintf(char *s, int n, char *fmt, ...);
Returns
The number of characters formatted into the buffer.
Parameters
char *s
is the buffer to receive the formatted string.
int n
is the maximum number of bytes allowed to be copied.
char *fmt
is the format string. The function handles only
%d
and
%s
strings; it
does not handle any width or precision strings.
...
represents a sequence of parameters for the
printf
function.
Summary of Contents for ENTERPRISE SERVER 6.1
Page 1: ...NSAPI Programmer s Guide Netscape Enterprise Server Version6 1 April 2002 Draft...
Page 290: ...Miscellaneous 290 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 318: ...cinfo 318 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 336: ...Buffered Streams 336 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 344: ...344 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 350: ...350 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...
Page 356: ...356 Netscape Enterprise Server NSAPI Programmer s Guide April 2002 Draft...