summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@dtucker.net>2019-11-01 15:22:32 +1100
committerDarren Tucker <dtucker@dtucker.net>2019-11-01 18:27:37 +1100
commit79d46de9fbea0f3c0e8ae7cf84effaba089071b0 (patch)
tree8f79bbf73e1d9edf251832b8723ce7420ea9db54
parentbb4f003ed8c5f61ec74a66bcedc8ab19bf5b35c4 (diff)
Use sftp_realpath if no native realpath.
-rw-r--r--configure.ac1
-rw-r--r--openbsd-compat/bsd-misc.h4
2 files changed, 5 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 8489384fb..a9cbfed0c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1783,6 +1783,7 @@ AC_CHECK_FUNCS([ \
1783 raise \ 1783 raise \
1784 readpassphrase \ 1784 readpassphrase \
1785 reallocarray \ 1785 reallocarray \
1786 realpath \
1786 recvmsg \ 1787 recvmsg \
1787 recallocarray \ 1788 recallocarray \
1788 rresvport_af \ 1789 rresvport_af \
diff --git a/openbsd-compat/bsd-misc.h b/openbsd-compat/bsd-misc.h
index 5a369d9de..429ade047 100644
--- a/openbsd-compat/bsd-misc.h
+++ b/openbsd-compat/bsd-misc.h
@@ -182,4 +182,8 @@ int flock(int, int);
182struct tm *localtime_r(const time_t *, struct tm *); 182struct tm *localtime_r(const time_t *, struct tm *);
183#endif 183#endif
184 184
185#ifndef HAVE_REALPATH
186#define realpath(x, y) (sftp_realpath((x), (y))
187#endif
188
185#endif /* _BSD_MISC_H */ 189#endif /* _BSD_MISC_H */