* [Qemu-devel] [PATCH] e1000: fix build on Ubuntu with _FORTIFY_SOURCE
@ 2010-03-31 9:22 Thomas Monjalon
2010-04-08 19:32 ` Aurelien Jarno
0 siblings, 1 reply; 2+ messages in thread
From: Thomas Monjalon @ 2010-03-31 9:22 UTC (permalink / raw)
To: qemu-devel; +Cc: Thomas Monjalon
From: Thomas Monjalon <thomas@monjalon.net>
There was a pointer cast warning on Ubuntu since _FORTIFY_SOURCE has been reenabled.
_FORTIFY_SOURCE had been disabled by 4a24470497360d8b77568b83008d0e9d6eb0787d
and reenabled by 849583050d5f6f782718be8cb50688978973fbea.
Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
---
hw/e1000.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/hw/e1000.c b/hw/e1000.c
index fd3059a..34cc451 100644
--- a/hw/e1000.c
+++ b/hw/e1000.c
@@ -642,7 +642,7 @@ e1000_receive(VLANClientState *nc, const uint8_t *buf, size_t size)
if (vlan_enabled(s) && is_vlan_packet(s, buf)) {
vlan_special = cpu_to_le16(be16_to_cpup((uint16_t *)(buf + 14)));
- memmove((void *)(buf + 4), buf, 12);
+ memmove((uint8_t *)buf + 4, buf, 12);
vlan_status = E1000_RXD_STAT_VP;
vlan_offset = 4;
size -= 4;
--
1.7.0.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] e1000: fix build on Ubuntu with _FORTIFY_SOURCE
2010-03-31 9:22 [Qemu-devel] [PATCH] e1000: fix build on Ubuntu with _FORTIFY_SOURCE Thomas Monjalon
@ 2010-04-08 19:32 ` Aurelien Jarno
0 siblings, 0 replies; 2+ messages in thread
From: Aurelien Jarno @ 2010-04-08 19:32 UTC (permalink / raw)
To: Thomas Monjalon; +Cc: Thomas Monjalon, qemu-devel
On Wed, Mar 31, 2010 at 11:22:51AM +0200, Thomas Monjalon wrote:
> From: Thomas Monjalon <thomas@monjalon.net>
>
> There was a pointer cast warning on Ubuntu since _FORTIFY_SOURCE has been reenabled.
>
> _FORTIFY_SOURCE had been disabled by 4a24470497360d8b77568b83008d0e9d6eb0787d
> and reenabled by 849583050d5f6f782718be8cb50688978973fbea.
>
> Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Thanks, applied.
> ---
> hw/e1000.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/hw/e1000.c b/hw/e1000.c
> index fd3059a..34cc451 100644
> --- a/hw/e1000.c
> +++ b/hw/e1000.c
> @@ -642,7 +642,7 @@ e1000_receive(VLANClientState *nc, const uint8_t *buf, size_t size)
>
> if (vlan_enabled(s) && is_vlan_packet(s, buf)) {
> vlan_special = cpu_to_le16(be16_to_cpup((uint16_t *)(buf + 14)));
> - memmove((void *)(buf + 4), buf, 12);
> + memmove((uint8_t *)buf + 4, buf, 12);
> vlan_status = E1000_RXD_STAT_VP;
> vlan_offset = 4;
> size -= 4;
> --
> 1.7.0.3
>
>
>
>
>
>
--
Aurelien Jarno GPG: 1024D/F1BCDB73
aurelien@aurel32.net http://www.aurel32.net
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-04-08 21:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-31 9:22 [Qemu-devel] [PATCH] e1000: fix build on Ubuntu with _FORTIFY_SOURCE Thomas Monjalon
2010-04-08 19:32 ` Aurelien Jarno
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).