From d9705c3be8e96e511be63a9ca480ebf0b7d56744 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Thu, 20 Jun 2002 21:36:25 +0000 Subject: 2002-06-20 Roland McGrath * firmlink.c (trivfs_S_io_read): Fix pointer arithmetic. Reported by Nicola Girardi . --- trans/firmlink.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'trans') diff --git a/trans/firmlink.c b/trans/firmlink.c index df8629ae..087e19d0 100644 --- a/trans/firmlink.c +++ b/trans/firmlink.c @@ -225,7 +225,7 @@ trivfs_S_io_read (struct trivfs_protid *cred, err = (*data == MAP_FAILED) ? errno : 0; if (!err && amount > 0) { - memcpy ((char *)(*data + start), target, amount); + memcpy (*data, target + start, amount); if (offs < 0) cred->po->hook = (void *)(start + amount); /* Update PO offset. */ } -- cgit v1.2.3