-/* $OpenBSD: extern.h,v 1.46 2021/02/19 08:14:49 claudio Exp $ */
+/* $OpenBSD: extern.h,v 1.47 2021/02/22 09:46:05 claudio Exp $ */
/*
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
*
void logx(const char *fmt, ...)
__attribute__((format(printf, 1, 2)));
-int mkpath(int, const char *);
+int mkpathat(int, const char *);
#define RPKI_PATH_OUT_DIR "/var/db/rpki-client"
#define RPKI_PATH_BASE_DIR "/var/cache/rpki-client"
-/* $OpenBSD: main.c,v 1.103 2021/02/19 12:18:23 tb Exp $ */
+/* $OpenBSD: main.c,v 1.104 2021/02/22 09:46:05 claudio Exp $ */
/*
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
*
* will not build the destination for us.
*/
- if (mkpath(cachefd, rp->local) == -1)
+ if (mkpathat(cachefd, rp->local) == -1)
err(1, "%s", rp->local);
logx("%s: pulling from network", rp->local);
-/* $OpenBSD: mkdir.c,v 1.2 2021/02/19 08:14:49 claudio Exp $ */
+/* $OpenBSD: mkdir.c,v 1.3 2021/02/22 09:46:05 claudio Exp $ */
/*
* Copyright (c) 1983, 1992, 1993
#include "extern.h"
/*
- * mkpath -- create directories.
+ * mkpathat -- create directories.
+ * dirfd - file descriptor for local directory
* path - path
* mode - file mode of terminal directory
* dir_mode - file mode of intermediate directories
*/
int
-mkpath(int dirfd, const char *dir)
+mkpathat(int dirfd, const char *dir)
{
char *path, *slash;
int done;