mirror of
https://github.com/curl/curl.git
synced 2026-08-25 15:43:47 +03:00
test1304: Added some unit tests for Curl_parsenetrc.
Moved some definitons into the header file so that we can reuse them.
This commit is contained in:
parent
3cffcba3d0
commit
39d0d787d2
6 changed files with 167 additions and 8 deletions
|
|
@ -61,11 +61,6 @@ enum host_lookup_state {
|
|||
HOSTEND /* LAST enum */
|
||||
};
|
||||
|
||||
/* make sure we have room for at least this size: */
|
||||
#define LOGINSIZE 64
|
||||
#define PASSWORDSIZE 64
|
||||
|
||||
/* returns -1 on failure, 0 if the host is found, 1 is the host isn't found */
|
||||
int Curl_parsenetrc(const char *host,
|
||||
char *login,
|
||||
char *password,
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 1998 - 2010, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
* Copyright (C) 1998 - 2011, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
|
|
@ -21,6 +21,12 @@
|
|||
* KIND, either express or implied.
|
||||
*
|
||||
***************************************************************************/
|
||||
|
||||
/* Make sure we have room for at least this size: */
|
||||
#define LOGINSIZE 64
|
||||
#define PASSWORDSIZE 64
|
||||
|
||||
/* returns -1 on failure, 0 if the host is found, 1 is the host isn't found */
|
||||
int Curl_parsenetrc(const char *host,
|
||||
char *login,
|
||||
char *password,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue