From 587cf4531c0a61c8916974ba39be9672e0b22f39 Mon Sep 17 00:00:00 2001 From: Can Erkin Acar Date: Thu, 8 Nov 2007 22:41:49 +0000 Subject: Pass correct pointers to memcpy when concatanating strings/buffers ok weingart@, marco@ --- sys/dev/acpi/dsdt.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sys') diff --git a/sys/dev/acpi/dsdt.c b/sys/dev/acpi/dsdt.c index 9139e3c8455..5473e2fcc4f 100644 --- a/sys/dev/acpi/dsdt.c +++ b/sys/dev/acpi/dsdt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dsdt.c,v 1.98 2007/11/08 20:27:20 canacar Exp $ */ +/* $OpenBSD: dsdt.c,v 1.99 2007/11/08 22:41:48 canacar Exp $ */ /* * Copyright (c) 2005 Jordan Hargrave * @@ -3186,14 +3186,14 @@ aml_parsestring(struct aml_scope *scope, int opcode, struct aml_value *res) tmpval[AML_RHS].type == AML_OBJTYPE_BUFFER) { aml_resize(&tmpval[AML_LHS], tmpval[AML_LHS].length+tmpval[AML_RHS].length); - memcpy(&tmpval[AML_LHS].v_buffer+tmpval[AML_LHS].length, + memcpy(tmpval[AML_LHS].v_buffer+tmpval[AML_LHS].length, tmpval[AML_RHS].v_buffer, tmpval[AML_RHS].length); aml_setvalue(scope, &tmpval[AML_DST], &tmpval[AML_LHS], 0); } else if (tmpval[AML_LHS].type == AML_OBJTYPE_STRING && tmpval[AML_RHS].type == AML_OBJTYPE_STRING) { aml_resize(&tmpval[AML_LHS], tmpval[AML_LHS].length+tmpval[AML_RHS].length); - memcpy(&tmpval[AML_LHS].v_string+tmpval[AML_LHS].length, + memcpy(tmpval[AML_LHS].v_string+tmpval[AML_LHS].length, tmpval[AML_RHS].v_buffer, tmpval[AML_RHS].length); aml_setvalue(scope, &tmpval[AML_DST], &tmpval[AML_LHS], 0); } else { -- cgit v1.2.3