Commit d4fc296c authored by Niels Möller's avatar Niels Möller

Cleanup.

Rev: src/client.h:1.8
Rev: src/format.c:1.13
Rev: src/lshd.c:1.9
Rev: src/publickey_crypto.c:1.11
Rev: src/read_packet.c:1.13
parent 806ea6dc
......@@ -51,12 +51,5 @@ make_client_callback(struct io_backend *b,
struct read_handler *make_client_read_line(struct ssh_connection *c);
struct callback *make_client_close_handler(void);
#if 0
struct client_session
{
struct read_handler handler;
UINT32 *
#endif
#endif /* LSH_CLIENT_H_INCLUDED */
......@@ -163,23 +163,6 @@ UINT32 ssh_vformat_length(char *f, va_list args)
f++;
break;
}
#if 0
case 'A':
{
int atom;
while ( (atom = va_arg(args, int)) )
length += get_atom_length(atom) + 1;
/* One ','-character less than the number of atoms */
length--;
if (!literal)
length += 4;
f++;
break;
}
#endif
case 'n':
{
MP_INT *n = va_arg(args, MP_INT*);
......@@ -346,40 +329,6 @@ UINT32 ssh_vformat(char *f, UINT8 *buffer, va_list args)
break;
}
#if 0
case 'A':
{
int atom;
UINT8 *start = buffer; /* Where to store the length */
if (!literal)
buffer += 4;
atom = va_arg(args, int);
if (atom)
{
UINT32 length = get_atom_length(atom);
memcpy(buffer, get_atom_name(atom), length);
buffer += length;
while ( (atom = va_arg(args, int)) )
{
*buffer++ = ',';
length = get_atom_length(atom);
memcpy(buffer, get_atom_name(atom), length);
buffer += length;
}
}
if (!literal)
{
UINT32 total = buffer - start - 4;
WRITE_UINT32(start, total);
}
f++;
break;
}
#endif
case 'A':
{
int *atom = va_arg(args, int *);
......
......@@ -41,11 +41,6 @@
#include "werror.h"
#include "xalloc.h"
#if 0
#include "crypto.h"
#include "publickey_crypto.h"
#endif
#define BLOCK_SIZE 32768
/* Global variable */
......
......@@ -220,13 +220,6 @@ int do_dss_verify(struct verifier *c,
int parse_dss_public(struct simple_buffer *buffer, struct dss_public *public)
{
#if 0
mpz_init(public->p);
mpz_init(public->q);
mpz_init(public->g);
mpz_init(public->y);
#endif
return (parse_bignum(buffer, public->p)
&& parse_bignum(buffer, public->p)
&& (mpz_sgn(public->p) == 1)
......@@ -239,13 +232,6 @@ int parse_dss_public(struct simple_buffer *buffer, struct dss_public *public)
&& parse_bignum(buffer, public->y)
&& (mpz_sgn(public->y) == 1)
&& (mpz_cmp(public->y, public->p) < 0) /* y < p */ );
#if 0
mpz_clear(public->p);
mpz_clear(public->q);
mpz_clear(public->g);
mpz_clear(public->y);
return 0;
#endif
}
/* FIXME: Outside of the protocol transactions, keys should be stored
......
......@@ -48,11 +48,6 @@ int do_read_packet(struct read_handler **h,
while(1)
{
#endif
#if 0
struct crypto_instance *crypto = connection->rec_crypto;
if (!crypto)
crypto = &crypto_none_instance;
#endif
switch(closure->state)
{
case WAIT_HEADER:
......@@ -77,9 +72,6 @@ int do_read_packet(struct read_handler **h,
case 0:
return 1;
case A_FAIL:
#if 0
werror("do_read_packet: read() failed, %s\n", strerror(errno));
#endif
/* Fall through */
case A_EOF:
/* FIXME: Free associated resources! */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment