termux-packages/packages/mympd/src-lib-http_client.c.patch

15 lines
539 B
Diff

--- a/src/lib/http_client.c
+++ b/src/lib/http_client.c
@@ -22,9 +22,9 @@
//read resolv.conf directly - musl does not support res_init
sds buffer = sdsempty();
errno = 0;
- FILE *fp = fopen("/etc/resolv.conf", OPEN_FLAGS_READ);
+ FILE *fp = fopen("@TERMUX_PREFIX@/etc/resolv.conf", OPEN_FLAGS_READ);
if (fp == NULL) {
- MYMPD_LOG_WARN("Can not open /etc/resolv.conf");
+ MYMPD_LOG_WARN("Can not open @TERMUX_PREFIX@/etc/resolv.conf");
MYMPD_LOG_ERRNO(errno);
return buffer;
}