2021-05-24 12:16:20 +02:00
|
|
|
Add inline with SNAPPY_ATTRIBUTE_ALWAYS_INLINE on AdvanceToNextTag to fix:
|
|
|
|
1097 | size_t tag_type = AdvanceToNextTag(&ip, &tag);
|
|
|
|
| ~~~~~~~~~~~~~~~~^~~~~~~~~~~
|
|
|
|
../snappy.cc:1017:8: error: inlining failed in call to 'always_inline'
|
|
|
|
'size_t snappy::AdvanceToNextTag(const uint8_t**, size_t*)': function body can be overwritten at link time
|
|
|
|
|
srcpkgs/s*: convert patches to -Np1
```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
```
2021-06-19 05:03:21 +02:00
|
|
|
--- a/snappy.cc 2021-05-05 02:53:34.000000000 +0400
|
|
|
|
+++ b/snappy.cc 2021-05-24 01:24:59.124654893 +0400
|
2021-05-24 12:16:20 +02:00
|
|
|
@@ -1017 +1017 @@ SNAPPY_ATTRIBUTE_ALWAYS_INLINE
|
|
|
|
-size_t AdvanceToNextTag(const uint8_t** ip_p, size_t* tag) {
|
|
|
|
+inline size_t AdvanceToNextTag(const uint8_t** ip_p, size_t* tag) {
|