Merge 'master'
This commit is contained in:
@@ -21,6 +21,8 @@ AC_REQUIRE([AC_PROG_LIBTOOL])
|
|||||||
|
|
||||||
AC_REQUIRE([AC_MIPS_ABI])
|
AC_REQUIRE([AC_MIPS_ABI])
|
||||||
|
|
||||||
|
AC_DEFINE(rk_PATH_DELIM, '/', [Path name delimiter])
|
||||||
|
|
||||||
dnl C characteristics
|
dnl C characteristics
|
||||||
|
|
||||||
AC_REQUIRE([AC_C___ATTRIBUTE__])
|
AC_REQUIRE([AC_C___ATTRIBUTE__])
|
||||||
|
@@ -13,4 +13,6 @@ typedef socklen_t krb5_socklen_t;
|
|||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
typedef ssize_t krb5_ssize_t;
|
typedef ssize_t krb5_ssize_t;
|
||||||
|
|
||||||
|
typedef int krb5_socket_t;
|
||||||
|
|
||||||
#endif /* __krb5_types_h__ */
|
#endif /* __krb5_types_h__ */
|
||||||
|
@@ -2,9 +2,7 @@
|
|||||||
|
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#ifndef HAVE_INT32_T
|
|
||||||
#include <krb5-types.h>
|
#include <krb5-types.h>
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef __asn1_common_definitions__
|
#ifndef __asn1_common_definitions__
|
||||||
#define __asn1_common_definitions__
|
#define __asn1_common_definitions__
|
||||||
|
@@ -32,6 +32,9 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#undef ROKEN_RENAME
|
#undef ROKEN_RENAME
|
||||||
|
|
||||||
|
#include "config.h"
|
||||||
|
|
||||||
#include "compile_et.h"
|
#include "compile_et.h"
|
||||||
#include <getarg.h>
|
#include <getarg.h>
|
||||||
|
|
||||||
@@ -219,19 +222,7 @@ main(int argc, char **argv)
|
|||||||
err(1, "%s", filename);
|
err(1, "%s", filename);
|
||||||
|
|
||||||
|
|
||||||
p = strrchr(filename, '/');
|
p = strrchr(filename, rk_PATH_DELIM);
|
||||||
#ifdef BACKSLASH_PATH_DELIM
|
|
||||||
{
|
|
||||||
char * bs = strrchr(filename, '\\');
|
|
||||||
|
|
||||||
if (p) {
|
|
||||||
if (p < bs)
|
|
||||||
p = bs;
|
|
||||||
} else {
|
|
||||||
p = bs;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
if(p)
|
if(p)
|
||||||
p++;
|
p++;
|
||||||
else
|
else
|
||||||
|
@@ -33,10 +33,6 @@ typedef struct direct DIRENTRY;
|
|||||||
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
|
||||||
#endif /* !defined(S_ISDIR) */
|
#endif /* !defined(S_ISDIR) */
|
||||||
|
|
||||||
#ifndef HAVE_CHAR
|
|
||||||
typedef unsigned char CHAR;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define MEM_INC 64
|
#define MEM_INC 64
|
||||||
#define SCREEN_INC 256
|
#define SCREEN_INC 256
|
||||||
|
|
||||||
|
@@ -145,8 +145,8 @@ read_string(const char *preprompt, const char *prompt,
|
|||||||
#else /* CONIO_H */
|
#else /* CONIO_H */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
read_string_conio(const char *preprompt, const char *prompt,
|
read_string(const char *preprompt, const char *prompt,
|
||||||
char *buf, size_t len, int echo)
|
char *buf, size_t len, int echo)
|
||||||
{
|
{
|
||||||
int of = 0;
|
int of = 0;
|
||||||
int c;
|
int c;
|
||||||
@@ -183,8 +183,6 @@ read_string_conio(const char *preprompt, const char *prompt,
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#define read_string read_string_conio
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
int
|
int
|
||||||
|
@@ -113,7 +113,7 @@ dir_iter_start(hx509_context context,
|
|||||||
free(d);
|
free(d);
|
||||||
return errno;
|
return errno;
|
||||||
}
|
}
|
||||||
#ifdef HAVE_DIRFD
|
#ifndef _WIN32
|
||||||
rk_cloexec(dirfd(d->dir));
|
rk_cloexec(dirfd(d->dir));
|
||||||
#endif
|
#endif
|
||||||
d->certs = NULL;
|
d->certs = NULL;
|
||||||
|
@@ -813,14 +813,14 @@ get_config_file_for_user(void)
|
|||||||
char *fn = NULL, *home = NULL;
|
char *fn = NULL, *home = NULL;
|
||||||
|
|
||||||
#ifndef _WIN32
|
#ifndef _WIN32
|
||||||
if (getuid() == geteuid()) {
|
if (!issuid()) {
|
||||||
fn = getenv("SOFTPKCS11RC");
|
fn = getenv("SOFTPKCS11RC");
|
||||||
if (fn)
|
if (fn)
|
||||||
fn = strdup(fn);
|
fn = strdup(fn);
|
||||||
home = getenv("HOME");
|
home = getenv("HOME");
|
||||||
}
|
}
|
||||||
if (fn == NULL && home == NULL) {
|
if (fn == NULL && home == NULL) {
|
||||||
struct passwd *pw = getpwuid(getuid());
|
struct passwd *pw = getpwuid(getuid());
|
||||||
if(pw != NULL)
|
if(pw != NULL)
|
||||||
home = pw->pw_dir;
|
home = pw->pw_dir;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user