1stoi(9F)                 Kernel Functions for Drivers                 stoi(9F)
2
3
4

NAME

6       stoi, numtos - convert between an integer and a decimal string
7

SYNOPSIS

9       #include <sys/ddi.h>
10
11       int stoi(char **str);
12
13
14       void numtos(unsigned long num, char *s);
15
16

INTERFACE LEVEL

18       Solaris DDI specific (Solaris DDI).
19

PARAMETERS

21       str    Pointer to a character string to be converted.
22
23
24       num    Decimal number to be converted to a character string.
25
26
27       s      Character buffer to hold converted decimal number.
28
29

DESCRIPTION

31   stoi()
32       The  stoi()  function  returns the integer value of a string of decimal
33       numeric characters beginning at **str. No overflow  checking  is  done.
34       *str is updated to point at the last character examined.
35
36   numtos()
37       The  numtos() function converts a long into a null-terminated character
38       string. No bounds checking is done. The caller  must  ensure  there  is
39       enough space to hold the result.
40

RETURN VALUES

42       The stoi() function returns the integer value of the string str.
43

CONTEXT

45       The  stoi() function can be called from user, interrupt, or kernel con‐
46       text.
47

SEE ALSO

49       Writing Device Drivers
50

NOTES

52       The stoi() function handles only positive integers; it does not  handle
53       leading minus signs.
54
55
56
57SunOS 5.11                        16 Jan 2006                         stoi(9F)
Impressum