From b7d17a492f93c10fe285708274837d9a7e10e3a6 Mon Sep 17 00:00:00 2001 From: Vladimir 'phcoder' Serbinenko Date: Fri, 12 Apr 2013 19:25:16 +0200 Subject: [PATCH] * grub-core/net/drivers/ieee1275/ofnet.c: Don't attempt to send more than buffer size. --- ChangeLog | 5 +++++ grub-core/net/drivers/ieee1275/ofnet.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 1f6ad7c0e..ced68cc38 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2013-04-12 Vladimir Serbinenko + + * grub-core/net/drivers/ieee1275/ofnet.c: Don't attempt to send more + than buffer size. + 2013-04-12 Vladimir Serbinenko Disable partmap check on i386-ieee1275 due to openfirmware issues. diff --git a/grub-core/net/drivers/ieee1275/ofnet.c b/grub-core/net/drivers/ieee1275/ofnet.c index 1acfb73fb..cd9b159c7 100644 --- a/grub-core/net/drivers/ieee1275/ofnet.c +++ b/grub-core/net/drivers/ieee1275/ofnet.c @@ -79,7 +79,7 @@ send_card_buffer (struct grub_net_card *dev, struct grub_net_buff *pack) grub_memcpy (dev->txbuf, pack->data, len); status = grub_ieee1275_write (data->handle, dev->txbuf, - pack->tail - pack->data, &actual); + len, &actual); if (status) return grub_error (GRUB_ERR_IO, N_("couldn't send network packet"));