ftp/axel: Fix build on some systems due to the conflict with if_t symbol
Reported by: fallout
This commit is contained in:
parent
4cbc811bc9
commit
56ca26b688
13
ftp/axel/files/patch-src_axel.h
Normal file
13
ftp/axel/files/patch-src_axel.h
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
- workaround for https://github.com/axel-download-accelerator/axel/issues/399
|
||||||
|
|
||||||
|
--- src/axel.h.orig 2023-01-22 20:28:34 UTC
|
||||||
|
+++ src/axel.h
|
||||||
|
@@ -101,7 +101,7 @@ typedef struct {
|
||||||
|
} message_t;
|
||||||
|
|
||||||
|
typedef message_t url_t;
|
||||||
|
-typedef message_t if_t;
|
||||||
|
+typedef message_t if_t_;
|
||||||
|
|
||||||
|
#include "abuf.h"
|
||||||
|
#include "conf.h"
|
54
ftp/axel/files/patch-src_conf.c
Normal file
54
ftp/axel/files/patch-src_conf.c
Normal file
|
@ -0,0 +1,54 @@
|
||||||
|
- workaround for https://github.com/axel-download-accelerator/axel/issues/399
|
||||||
|
|
||||||
|
--- src/conf.c.orig 2023-01-22 20:28:48 UTC
|
||||||
|
+++ src/conf.c
|
||||||
|
@@ -276,7 +276,7 @@ conf_init(conf_t *conf)
|
||||||
|
"User-Agent", DEFAULT_USER_AGENT);
|
||||||
|
conf->add_header_count = HDR_count_init;
|
||||||
|
|
||||||
|
- conf->interfaces = calloc(1, sizeof(if_t));
|
||||||
|
+ conf->interfaces = calloc(1, sizeof(if_t_));
|
||||||
|
if (!conf->interfaces)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
@@ -329,11 +329,11 @@ int
|
||||||
|
parse_interfaces(conf_t *conf, char *s)
|
||||||
|
{
|
||||||
|
char *s2;
|
||||||
|
- if_t *iface;
|
||||||
|
+ if_t_ *iface;
|
||||||
|
|
||||||
|
iface = conf->interfaces->next;
|
||||||
|
while (iface != conf->interfaces) {
|
||||||
|
- if_t *i;
|
||||||
|
+ if_t_ *i;
|
||||||
|
|
||||||
|
i = iface->next;
|
||||||
|
free(iface);
|
||||||
|
@@ -342,7 +342,7 @@ parse_interfaces(conf_t *conf, char *s)
|
||||||
|
free(conf->interfaces);
|
||||||
|
|
||||||
|
if (!*s) {
|
||||||
|
- conf->interfaces = calloc(1, sizeof(if_t));
|
||||||
|
+ conf->interfaces = calloc(1, sizeof(if_t_));
|
||||||
|
if (!conf->interfaces)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
@@ -350,7 +350,7 @@ parse_interfaces(conf_t *conf, char *s)
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
- conf->interfaces = iface = malloc(sizeof(if_t));
|
||||||
|
+ conf->interfaces = iface = malloc(sizeof(if_t_));
|
||||||
|
if (!conf->interfaces)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
@@ -365,7 +365,7 @@ parse_interfaces(conf_t *conf, char *s)
|
||||||
|
strlcpy(iface->text, s, sizeof(iface->text));
|
||||||
|
s = s2 + 1;
|
||||||
|
if (*s) {
|
||||||
|
- iface->next = malloc(sizeof(if_t));
|
||||||
|
+ iface->next = malloc(sizeof(if_t_));
|
||||||
|
if (!iface->next)
|
||||||
|
return 0;
|
||||||
|
|
13
ftp/axel/files/patch-src_conf.h
Normal file
13
ftp/axel/files/patch-src_conf.h
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
- workaround for https://github.com/axel-download-accelerator/axel/issues/399
|
||||||
|
|
||||||
|
--- src/conf.h.orig 2023-01-22 20:27:54 UTC
|
||||||
|
+++ src/conf.h
|
||||||
|
@@ -65,7 +65,7 @@ typedef struct {
|
||||||
|
AXEL_PROGRESS_STYLE_PERCENTAGE,
|
||||||
|
} progress_style;
|
||||||
|
|
||||||
|
- if_t *interfaces;
|
||||||
|
+ if_t_ *interfaces;
|
||||||
|
|
||||||
|
sa_family_t ai_family;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user