Move definition of h_errno from lib_parsehostfile.c to lib_netdb. h_errno should still be defined even if there is no host file support. From Sebastien Lorquet.

This commit is contained in:
Sebastien Lorquet 2015-07-17 09:39:45 -06:00 committed by Gregory Nutt
parent cb5a3bd84d
commit 4eec7041fc
2 changed files with 8 additions and 11 deletions

View File

@ -52,6 +52,14 @@
struct hostent g_hostent; struct hostent g_hostent;
char g_hostbuffer[CONFIG_NETDB_BUFSIZE]; char g_hostbuffer[CONFIG_NETDB_BUFSIZE];
/* When the <netdb.h> header is included, h_errno shall be available as a
* modifiable lvalue of type int. It is unspecified whether h_errno is a
* macro or an identifier declared with external linkage.
*/
/* REVISIT: This should at least be per-task? */
int h_errno;
/**************************************************************************** /****************************************************************************
* Public Functions * Public Functions
****************************************************************************/ ****************************************************************************/

View File

@ -76,17 +76,6 @@ struct hostent_info_s
char hi_data[1]; char hi_data[1];
}; };
/****************************************************************************
* Public Data
****************************************************************************/
/* When the <netdb.h> header is included, h_errno shall be available as a
* modifiable lvalue of type int. It is unspecified whether h_errno is a
* macro or an identifier declared with external linkage.
*/
/* REVISIT: This should at least be per-task? */
int h_errno;
/**************************************************************************** /****************************************************************************
* Private functions * Private functions