mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-10 09:58:01 +00:00
Make ssh1_pkt_type(), ssh2_pkt_type, logeventf(), setup_userpass_input(),
process_userpass_input(), and ssh_unthrottle() static, since they're not referenced outside this file. [originally from svn r2475]
This commit is contained in:
parent
3f055f22d8
commit
88b1506298
12
ssh.c
12
ssh.c
@ -166,7 +166,7 @@ static const char *const ssh2_disconnect_reasons[] = {
|
|||||||
|
|
||||||
#define translate(x) if (type == x) return #x
|
#define translate(x) if (type == x) return #x
|
||||||
#define translatec(x,ctx) if (type == x && (pkt_ctx & ctx)) return #x
|
#define translatec(x,ctx) if (type == x && (pkt_ctx & ctx)) return #x
|
||||||
char *ssh1_pkt_type(int type)
|
static char *ssh1_pkt_type(int type)
|
||||||
{
|
{
|
||||||
translate(SSH1_MSG_DISCONNECT);
|
translate(SSH1_MSG_DISCONNECT);
|
||||||
translate(SSH1_SMSG_PUBLIC_KEY);
|
translate(SSH1_SMSG_PUBLIC_KEY);
|
||||||
@ -211,7 +211,7 @@ char *ssh1_pkt_type(int type)
|
|||||||
translate(SSH1_CMSG_AUTH_CCARD_RESPONSE);
|
translate(SSH1_CMSG_AUTH_CCARD_RESPONSE);
|
||||||
return "unknown";
|
return "unknown";
|
||||||
}
|
}
|
||||||
char *ssh2_pkt_type(int pkt_ctx, int type)
|
static char *ssh2_pkt_type(int pkt_ctx, int type)
|
||||||
{
|
{
|
||||||
translate(SSH2_MSG_DISCONNECT);
|
translate(SSH2_MSG_DISCONNECT);
|
||||||
translate(SSH2_MSG_IGNORE);
|
translate(SSH2_MSG_IGNORE);
|
||||||
@ -625,7 +625,7 @@ struct ssh_tag {
|
|||||||
#define logevent(s) logevent(ssh->frontend, s)
|
#define logevent(s) logevent(ssh->frontend, s)
|
||||||
|
|
||||||
/* logevent, only printf-formatted. */
|
/* logevent, only printf-formatted. */
|
||||||
void logeventf(Ssh ssh, char *fmt, ...)
|
static void logeventf(Ssh ssh, char *fmt, ...)
|
||||||
{
|
{
|
||||||
va_list ap;
|
va_list ap;
|
||||||
char *buf;
|
char *buf;
|
||||||
@ -2125,7 +2125,7 @@ static void ssh_throttle_all(Ssh ssh, int enable, int bufsize)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* Set up a username or password input loop on a given buffer. */
|
/* Set up a username or password input loop on a given buffer. */
|
||||||
void setup_userpass_input(Ssh ssh, char *buffer, int buflen, int echo)
|
static void setup_userpass_input(Ssh ssh, char *buffer, int buflen, int echo)
|
||||||
{
|
{
|
||||||
ssh->userpass_input_buffer = buffer;
|
ssh->userpass_input_buffer = buffer;
|
||||||
ssh->userpass_input_buflen = buflen;
|
ssh->userpass_input_buflen = buflen;
|
||||||
@ -2139,7 +2139,7 @@ void setup_userpass_input(Ssh ssh, char *buffer, int buflen, int echo)
|
|||||||
* buffer), <0 for failure (user hit ^C/^D, bomb out and exit), 0
|
* buffer), <0 for failure (user hit ^C/^D, bomb out and exit), 0
|
||||||
* for inconclusive (keep waiting for more input please).
|
* for inconclusive (keep waiting for more input please).
|
||||||
*/
|
*/
|
||||||
int process_userpass_input(Ssh ssh, unsigned char *in, int inlen)
|
static int process_userpass_input(Ssh ssh, unsigned char *in, int inlen)
|
||||||
{
|
{
|
||||||
char c;
|
char c;
|
||||||
|
|
||||||
@ -6087,7 +6087,7 @@ void *new_sock_channel(void *handle, Socket s)
|
|||||||
* This is called when stdout/stderr (the entity to which
|
* This is called when stdout/stderr (the entity to which
|
||||||
* from_backend sends data) manages to clear some backlog.
|
* from_backend sends data) manages to clear some backlog.
|
||||||
*/
|
*/
|
||||||
void ssh_unthrottle(void *handle, int bufsize)
|
static void ssh_unthrottle(void *handle, int bufsize)
|
||||||
{
|
{
|
||||||
Ssh ssh = (Ssh) handle;
|
Ssh ssh = (Ssh) handle;
|
||||||
if (ssh->version == 1) {
|
if (ssh->version == 1) {
|
||||||
|
Loading…
Reference in New Issue
Block a user