/* we need a blocking fd here as recv() might return EAGAIN otherwise. */
ret = mark_fd_blocking(fd);
if (ret < 0)
- goto err_out;
+ goto net_err;
/* send Welcome message */
ret = send_va_buffer(fd, "This is para_server, version "
PACKAGE_VERSION ".\n" );
if (ret < 0)
- goto err_out;
+ goto net_err;
/* recv auth request line */
ret = recv_buffer(fd, buf, sizeof(buf));
if (ret < 0)
- goto err_out;
+ goto net_err;
if (ret < 10) {
ret = -E_AUTH_REQUEST;
- goto err_out;
+ goto net_err;
}
numbytes = ret;
ret = -E_AUTH_REQUEST;
if (strncmp(buf, AUTH_REQUEST_MSG, strlen(AUTH_REQUEST_MSG)))
- goto err_out;
+ goto net_err;
p = buf + strlen(AUTH_REQUEST_MSG);
PARA_DEBUG_LOG("received auth request for user %s\n", p);
ret = -E_BAD_USER;
ret = para_encrypt_buffer(u->rsa, rand_buf, sizeof(rand_buf),
(unsigned char *)buf);
if (ret < 0)
- goto err_out;
+ goto net_err;
numbytes = ret;
} else {
/*