I think *readline() makes a better name

This commit is contained in:
Daniel Stenberg 2009-05-29 00:19:02 +02:00
parent 4df48aef41
commit 82bdd12a8b
2 changed files with 7 additions and 7 deletions

View File

@ -780,7 +780,7 @@ LIBSSH2_API void
libssh2_knownhost_free(LIBSSH2_KNOWNHOSTS *hosts);
/*
* libssh2_knownhost_read()
* libssh2_knownhost_readline()
*
* Pass in a line of a file of 'type'. It makes libssh2 read this line.
*
@ -788,8 +788,8 @@ libssh2_knownhost_free(LIBSSH2_KNOWNHOSTS *hosts);
*
*/
LIBSSH2_API int
libssh2_knownhost_read(LIBSSH2_KNOWNHOSTS *hosts,
const char *line, size_t len, int type);
libssh2_knownhost_readline(LIBSSH2_KNOWNHOSTS *hosts,
const char *line, size_t len, int type);
/*
* libssh2_knownhost_readfile

View File

@ -487,7 +487,7 @@ static int hostline(LIBSSH2_KNOWNHOSTS *hosts,
}
/*
* libssh2_knownhost_read()
* libssh2_knownhost_readline()
*
* Pass in a line of a file of 'type'.
*
@ -515,8 +515,8 @@ static int hostline(LIBSSH2_KNOWNHOSTS *hosts,
*
*/
LIBSSH2_API int
libssh2_knownhost_read(LIBSSH2_KNOWNHOSTS *hosts,
const char *line, size_t len, int type)
libssh2_knownhost_readline(LIBSSH2_KNOWNHOSTS *hosts,
const char *line, size_t len, int type)
{
const char *cp;
const char *hostp;
@ -603,7 +603,7 @@ libssh2_knownhost_readfile(LIBSSH2_KNOWNHOSTS *hosts,
file = fopen(filename, "r");
if(file) {
while(fgets(buf, sizeof(buf), file)) {
if(libssh2_knownhost_read(hosts, buf, strlen(buf), type))
if(libssh2_knownhost_readline(hosts, buf, strlen(buf), type))
break;
num++;
}