All of lore.kernel.org
 help / color / mirror / Atom feed
From: jdl at freescale.com <jdl@freescale.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH] Fixed an OF-tree off-by-one bug when adding a new property name.
Date: Tue, 29 Aug 2006 09:02:54 -0500	[thread overview]
Message-ID: <E1GI4B4-0008ER-Ti@jdl.com> (raw)

This bug will cause the kernel booting to pause a long time.

Signed-off-by: Zhang Wei <wei.zhang@freescale.com>
Signed-off-by: Jon Loeliger <jdl@freescale.com>
---

Note:
    This patch is on top of the patches supplied by Matthew McClintock.
    Specifically, [PATCH 2/11] of June 27, 2006 with Subject:
        Patch to modify ft_build.c to update flat device trees in place

CHANGELOG:

* Fix an off-by-one bug in OF-tree property handling.
  Patch by Zhang Wei, 28 Aug 2006


 common/ft_build.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/common/ft_build.c b/common/ft_build.c
index b5a997c..b5937e3 100644
--- a/common/ft_build.c
+++ b/common/ft_build.c
@@ -103,7 +103,7 @@ void ft_prop(struct ft_cxt *cxt, const c
 	if (off == -1) {
 		memcpy(cxt->p_end, name, strlen(name) + 1);
 		off = cxt->p_end - cxt->p;
-		cxt->p_end += strlen(name) + 2;
+		cxt->p_end += strlen(name) + 1;
 	}
 
 	/* now put offset from beginning of *STRUCTURE* */
-- 
1.4.2.rc2.g85d6c-dirty

                 reply	other threads:[~2006-08-29 14:02 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E1GI4B4-0008ER-Ti@jdl.com \
    --to=jdl@freescale.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.