summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /sys-apps/iproute2/files/iproute2-3.7.0-clang.patch
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'sys-apps/iproute2/files/iproute2-3.7.0-clang.patch')
-rw-r--r--sys-apps/iproute2/files/iproute2-3.7.0-clang.patch72
1 files changed, 72 insertions, 0 deletions
diff --git a/sys-apps/iproute2/files/iproute2-3.7.0-clang.patch b/sys-apps/iproute2/files/iproute2-3.7.0-clang.patch
new file mode 100644
index 000000000000..17bb6ac856b3
--- /dev/null
+++ b/sys-apps/iproute2/files/iproute2-3.7.0-clang.patch
@@ -0,0 +1,72 @@
+From 048bff6e0206bca33ee70516521f3048e7714752 Mon Sep 17 00:00:00 2001
+From: Mike Frysinger <vapier@gentoo.org>
+Date: Thu, 17 Jan 2013 18:00:50 +0000
+Subject: [PATCH] ipxfrm: use alloca to allocate stack space
+
+Clang doesn't support the gcc extension for embeddeding flexible arrays
+inside of structures. Use the slightly more portable alloca().
+
+Signed-off-by: Mike Frysinger <vapier@gentoo.org>
+---
+ ip/ipxfrm.c | 27 +++++++++++----------------
+ 1 file changed, 11 insertions(+), 16 deletions(-)
+
+diff --git a/ip/ipxfrm.c b/ip/ipxfrm.c
+index c7b3420..dda4a7a 100644
+--- a/ip/ipxfrm.c
++++ b/ip/ipxfrm.c
+@@ -25,6 +25,7 @@
+ * Masahide NAKAMURA @USAGI
+ */
+
++#include <alloca.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <string.h>
+@@ -555,16 +556,13 @@ static inline void xfrm_algo_print(struct xfrm_algo *algo, int type, int len,
+ static void xfrm_aead_print(struct xfrm_algo_aead *algo, int len,
+ FILE *fp, const char *prefix)
+ {
+- struct {
+- struct xfrm_algo algo;
+- char key[algo->alg_key_len / 8];
+- } base;
++ struct xfrm_algo *base_algo = alloca(sizeof(*base_algo) + algo->alg_key_len / 8);
+
+- memcpy(base.algo.alg_name, algo->alg_name, sizeof(base.algo.alg_name));
+- base.algo.alg_key_len = algo->alg_key_len;
+- memcpy(base.algo.alg_key, algo->alg_key, algo->alg_key_len / 8);
++ memcpy(base_algo->alg_name, algo->alg_name, sizeof(base_algo->alg_name));
++ base_algo->alg_key_len = algo->alg_key_len;
++ memcpy(base_algo->alg_key, algo->alg_key, algo->alg_key_len / 8);
+
+- __xfrm_algo_print(&base.algo, XFRMA_ALG_AEAD, len, fp, prefix, 0);
++ __xfrm_algo_print(base_algo, XFRMA_ALG_AEAD, len, fp, prefix, 0);
+
+ fprintf(fp, " %d", algo->alg_icv_len);
+
+@@ -574,16 +572,13 @@ static void xfrm_aead_print(struct xfrm_algo_aead *algo, int len,
+ static void xfrm_auth_trunc_print(struct xfrm_algo_auth *algo, int len,
+ FILE *fp, const char *prefix)
+ {
+- struct {
+- struct xfrm_algo algo;
+- char key[algo->alg_key_len / 8];
+- } base;
++ struct xfrm_algo *base_algo = alloca(sizeof(*base_algo) + algo->alg_key_len / 8);
+
+- memcpy(base.algo.alg_name, algo->alg_name, sizeof(base.algo.alg_name));
+- base.algo.alg_key_len = algo->alg_key_len;
+- memcpy(base.algo.alg_key, algo->alg_key, algo->alg_key_len / 8);
++ memcpy(base_algo->alg_name, algo->alg_name, sizeof(base_algo->alg_name));
++ base_algo->alg_key_len = algo->alg_key_len;
++ memcpy(base_algo->alg_key, algo->alg_key, algo->alg_key_len / 8);
+
+- __xfrm_algo_print(&base.algo, XFRMA_ALG_AUTH_TRUNC, len, fp, prefix, 0);
++ __xfrm_algo_print(base_algo, XFRMA_ALG_AUTH_TRUNC, len, fp, prefix, 0);
+
+ fprintf(fp, " %d", algo->alg_trunc_len);
+
+--
+1.8.0.2
+