~ubuntu-branches/ubuntu/saucy/nut/saucy

« back to all changes in this revision

Viewing changes to server/ssl.c

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2005-07-20 19:48:50 UTC
  • mto: (16.1.1 squeeze)
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: james.westby@ubuntu.com-20050720194850-oo61wjr33rrx2mre
Tags: upstream-2.0.2
ImportĀ upstreamĀ versionĀ 2.0.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
#include "ctype.h"
30
30
#include "neterr.h"
31
31
 
 
32
#include "ssl.h"
 
33
 
32
34
        char    *certfile = NULL;
33
35
 
34
36
static  int     ssl_initialized = 0;
36
38
#ifndef HAVE_SSL
37
39
 
38
40
/* stubs for non-ssl compiles */
39
 
void do_starttls(ctype *client, char *arg, char *rest)
 
41
void net_starttls(ctype *client, int numarg, const char **arg)
40
42
{
41
43
        send_err(client, NUT_ERR_FEATURE_NOT_SUPPORTED);
 
44
        return;
42
45
}
43
46
 
44
47
int ssl_write(ctype *client, const char *buf, size_t buflen)
80
83
        }
81
84
}
82
85
 
83
 
void do_starttls(ctype *client, char *arg, char *rest)
 
86
void net_starttls(ctype *client, int numarg, const char **arg)
84
87
{
85
88
        if (client->ssl) {
86
89
                send_err(client, NUT_ERR_ALREADY_SSL_MODE);
172
175
                                        ret);
173
176
                        break;
174
177
 
175
 
                default:
 
178
                default:
176
179
                        upsdebugx(1, "ssl_error() ret=%d SSL_ERROR %d", ret, e);
177
180
                        ssl_debug();
178
 
        }
 
181
        }
179
182
 
180
183
        return -1;
181
184
}