random fixes to make it build with socks
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@5028 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -119,7 +119,12 @@
|
||||
|
||||
#ifdef SOCKS
|
||||
#include <socks.h>
|
||||
extern int LIBPREFIX(fclose) __P((FILE *));
|
||||
extern int LIBPREFIX(fclose) (FILE *);
|
||||
|
||||
/* This doesn't belong here. */
|
||||
struct tm *localtime(const time_t *);
|
||||
struct hostent *gethostbyname(const char *);
|
||||
|
||||
#endif
|
||||
|
||||
#include "ftp_var.h"
|
||||
|
@@ -203,6 +203,7 @@ mk_auth(struct krb4_data *d, KTEXT adat,
|
||||
int ret;
|
||||
CREDENTIALS cred;
|
||||
char sname[SNAME_SZ], inst[INST_SZ], realm[REALM_SZ];
|
||||
|
||||
strcpy_truncate(sname, service, sizeof(sname));
|
||||
strcpy_truncate(inst, krb_get_phost(host), sizeof(inst));
|
||||
strcpy_truncate(realm, krb_realmofhost(host), sizeof(realm));
|
||||
|
@@ -1100,7 +1100,7 @@ yylex(void)
|
||||
#ifdef HAVE_SETPROCTITLE
|
||||
if (strncasecmp(cbuf, "PASS", 4) != NULL)
|
||||
setproctitle("%s: %s", proctitle, cbuf);
|
||||
#endif
|
||||
#endif /* HAVE_SETPROCTITLE */
|
||||
if ((cp = strchr(cbuf, '\r'))) {
|
||||
*cp++ = '\n';
|
||||
*cp = '\0';
|
||||
@@ -1385,7 +1385,8 @@ sizecmd(char *filename)
|
||||
reply(550, "%s: not a plain file.", filename);
|
||||
else
|
||||
reply(213, "%lu", (unsigned long)stbuf.st_size);
|
||||
break; }
|
||||
break;
|
||||
}
|
||||
case TYPE_A: {
|
||||
FILE *fin;
|
||||
int c;
|
||||
@@ -1411,7 +1412,8 @@ sizecmd(char *filename)
|
||||
fclose(fin);
|
||||
|
||||
reply(213, "%lu", (unsigned long)count);
|
||||
break; }
|
||||
break;
|
||||
}
|
||||
default:
|
||||
reply(504, "SIZE not implemented for Type %c.", "?AEIL"[type]);
|
||||
}
|
||||
|
@@ -158,7 +158,7 @@
|
||||
|
||||
#ifdef SOCKS
|
||||
#include <socks.h>
|
||||
extern int LIBPREFIX(fclose) __P((FILE *));
|
||||
extern int LIBPREFIX(fclose) (FILE *);
|
||||
#endif
|
||||
|
||||
int yyparse();
|
||||
|
@@ -88,7 +88,7 @@ store_ticket(KTEXT cip)
|
||||
len = strnlen(ptr, left);
|
||||
if (len == left)
|
||||
return(INTK_BADPW);
|
||||
|
||||
|
||||
/* extract server's instance */
|
||||
strcpy_truncate(sp.instance, ptr, sizeof(sp.instance));
|
||||
ptr += len + 1;
|
||||
@@ -97,7 +97,7 @@ store_ticket(KTEXT cip)
|
||||
len = strnlen(ptr, left);
|
||||
if (len == left)
|
||||
return(INTK_BADPW);
|
||||
|
||||
|
||||
/* extract server's realm */
|
||||
strcpy_truncate(sp.realm, ptr, sizeof(sp.realm));
|
||||
ptr += len + 1;
|
||||
|
Reference in New Issue
Block a user