Git init
[external/curl.git] / docs / libcurl / curl_getenv.3
1 .\"
2 .TH curl_getenv 3 "30 April 2004" "libcurl 7.12" "libcurl Manual"
3 .SH NAME
4 curl_getenv - return value for environment name
5 .SH SYNOPSIS
6 .B #include <curl/curl.h>
7 .sp
8 .BI "char *curl_getenv(const char *" name ");"
9 .ad
10 .SH DESCRIPTION
11 curl_getenv() is a portable wrapper for the getenv() function, meant to
12 emulate its behaviour and provide an identical interface for all operating
13 systems libcurl builds on (including win32).
14 .SH AVAILABILITY
15 This function will be removed from the public libcurl API in a near future. It
16 will instead be made "available" by source code access only, and then as
17 curlx_getenv().
18 .SH RETURN VALUE
19 If successful, curl_getenv() returns a pointer to the value of the specified
20 environment. The memory it refers to is malloc()ed so the application must
21 free() this when the data is no longer needed. When \fIcurl_getenv(3)\fP fails
22 to find the specified name, it returns a null pointer.
23 .SH NOTE
24 Under unix operating systems, there isn't any point in returning an allocated
25 memory, although other systems won't work properly if this isn't done. The
26 unix implementation thus has to suffer slightly from the drawbacks of other
27 systems.
28 .SH "SEE ALSO"
29 .BR getenv "(3C), "