4b97cd2fb4
```sh git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" | while read template; do for p in ${template%/template}/patches/*; do sed -i ' \,^[+-][+-][+-] /dev/null,b /^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b s,^[*][*][*] ,&a/, /^--- /{ s,\(^--- \)\(./\)*,\1a/, s,[.-][Oo][Rr][Ii][Gg]\([ /]\),\1, s/[.-][Oo][Rr][Ii][Gg]$// s/[.]patched[.]\([^.]\)/.\1/ h } /^+++ -/{ g s/^--- a/+++ b/ b } s,\(^+++ \)\(./\)*,\1b/, ' "$p" done sed -i '/^patch_args=/d' $template done ```
17 lines
850 B
Diff
17 lines
850 B
Diff
Patch from https://github.com/supertuxkart/stk-code/pull/4361
|
|
|
|
Necessary because musl does not (yet?) implement ns_name_ntop.
|
|
|
|
diff --git a/src/network/network_config.cpp b/src/network/network_config.cpp
|
|
index 605254808..fd4fd5d24 100644
|
|
--- a/src/network/network_config.cpp
|
|
+++ b/src/network/network_config.cpp
|
|
@@ -587,7 +587,7 @@ void NetworkConfig::fillStunList(std::vector<std::pair<std::string, int> >* l,
|
|
for (unsigned i = 0; i < srv.size(); i++)
|
|
{
|
|
char server_name[512] = {};
|
|
- if (ns_name_ntop(srv[i] + SRV_SERVER, server_name, 512) < 0)
|
|
+ if (ns_name_uncompress(response, response + response_len, srv[i] + SRV_SERVER, server_name, 512) < 0)
|
|
continue;
|
|
uint16_t port = ns_get16(srv[i] + SRV_PORT);
|
|
uint16_t weight = ns_get16(srv[i] + SRV_WEIGHT);
|