This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RFA: document & fix sim/sh/interp.c:strswaplen (Was: Re: Bug in sh/interp.c?) (repost)


>From joern.rennecke@superh.com Wed Oct 22 13:37:54 2003
Received: from cartero.cs.tu-berlin.de (postfix@cartero.cs.tu-berlin.de [130.149.17.20])
	by mail.cs.tu-berlin.de (8.9.3p2/8.9.3) with ESMTP id NAA22220
	for <amylaar@cs.tu-berlin.de>; Wed, 22 Oct 2003 13:37:51 +0200 (MET DST)
Received: from localhost (localhost [127.0.0.1])
	by localhost-10025.cs.tu-berlin.de (Postfix) with ESMTP id 701F6195C82
	for <amylaar@cs.tu-berlin.de>; Wed, 22 Oct 2003 13:37:51 +0200 (MEST)
Received: from cartero.cs.tu-berlin.de ([127.0.0.1])
 by localhost (cartero [127.0.0.1]) (amavisd-new, port 10024) with ESMTP
 id 03011-03 for <amylaar@cs.tu-berlin.de>;
 Wed, 22 Oct 2003 13:37:51 +0200 (MEST)
Received: from smtp.uk.superh.com (ns2.uk.superh.com [193.128.105.170])
	by cartero.cs.tu-berlin.de (Postfix) with ESMTP id 3CD27130BAE
	for <amylaar@cs.tu-berlin.de>; Wed, 22 Oct 2003 13:37:44 +0200 (MEST)
Received: from sh-uk-ex01.uk.w2k.superh.com (sh-uk-ex01 [192.168.16.17])
	by smtp.uk.superh.com (8.12.10/8.12.9) with ESMTP id h9MBRjZi028308
	for <amylaar@cs.tu-berlin.de>; Wed, 22 Oct 2003 12:27:45 +0100 (BST)
Received: from linsvr2.uk.superh.com ([192.168.16.51]) by sh-uk-ex01.uk.w2k.superh.com with Microsoft SMTPSVC(5.0.2195.5329);
	 Wed, 22 Oct 2003 12:38:41 +0100
Received: (from renneckej@localhost)
	by linsvr2.uk.superh.com (8.11.6/8.11.6) id h9MBbbE26606
	for amylaar@cs.tu-berlin.de; Wed, 22 Oct 2003 12:37:37 +0100
From: Joern Rennecke <joern.rennecke@superh.com>
Message-Id: <200310221137.h9MBbbE26606@linsvr2.uk.superh.com>
Subject: RFA: document & fix sim/sh/interp.c:strswaplen (Was: Re: Bug in sh/interp.c?) (fwd)
To: amylaar@cs.tu-berlin.de
Date: Wed, 22 Oct 2003 12:37:37 +0100 (BST)
X-Mailer: ELM [version 2.5 PL6]
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-OriginalArrivalTime: 22 Oct 2003 11:38:41.0295 (UTC) FILETIME=[0AA7B9F0:01C39891]
X-Scanned-By: MIMEDefang 2.37
X-Virus-Scanned: by amavisd-new at cs.tu-berlin.de
Content-Length: 2387

>From renneckej  Thu Oct 16 18:00:47 2003
Received: from sh-uk-ex01.uk.w2k.superh.com [192.168.16.17]
	by localhost with IMAP (fetchmail-5.9.0)
	for renneckej@localhost (single-drop); Thu, 16 Oct 2003 18:00:47 +0100 (BST)
Received: from linsvr1.uk.superh.com ([192.168.16.50]) by sh-uk-ex01.uk.w2k.superh.com with Microsoft SMTPSVC(5.0.2195.5329);
	 Thu, 16 Oct 2003 18:00:04 +0100
Received: (from renneckej@localhost)
	by linsvr1.uk.superh.com (8.11.6/8.11.6) id h9GGx5I16086;
	Thu, 16 Oct 2003 17:59:05 +0100
From: Joern Rennecke <joern.rennecke@superh.com>
Message-Id: <200310161659.h9GGx5I16086@linsvr1.uk.superh.com>
Subject: RFA: document & fix sim/sh/interp.c:strswaplen (Was: Re: Bug in sh/interp.c?)
To: gdb-patches@sources.redhat.com
Date: Thu, 16 Oct 2003 17:59:04 +0100 (BST)
Cc: joern.rennecke@superh.com (Joern Rennecke), Frank.Yellin@Sun.COM,
   cagney@redhat.com, bje@redhat.com
In-Reply-To: <3F78A4C2.1010603@sfbay.sun.com> from "Frank Yellin" at Sep 29, 2003 02:31:46 
X-Mailer: ELM [version 2.5 PL6]
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Return-Path: joern.rennecke@superh.com
X-OriginalArrivalTime: 16 Oct 2003 17:00:04.0303 (UTC) FILETIME=[F1BEBDF0:01C39406]

2003-10-16  J"orn Rennecke <joern.rennecke@superh.com>

	* interp.c (strswaplen): Add one for '\0' delimiter.

Index: interp.c
===================================================================
RCS file: /cvs/src/src/sim/sh/interp.c,v
retrieving revision 1.11
diff -p -r1.11 interp.c
*** interp.c	15 Oct 2003 12:30:47 -0000	1.11
--- interp.c	16 Oct 2003 16:55:13 -0000
*************** ptr (x)
*** 920,925 ****
--- 920,929 ----
    return (char *) (x + saved_state.asregs.memory);
  }
  
+ /* STR points to a zero-terminated string in target byte order.  Return
+    the number of bytes that need to be converted to host byte order in order
+    to use this string as a zero-terminated string on the host.
+    (Not counting the rounding up needed to operate on entire words.)  */
  static int
  strswaplen (str)
       int str;
*************** strswaplen (str)
*** 932,938 ****
      return 0;
    end = str;
    for (end = str; memory[end ^ endian]; end++) ;
!   return end - str;
  }
  
  static void
--- 936,942 ----
      return 0;
    end = str;
    for (end = str; memory[end ^ endian]; end++) ;
!   return end - str + 1;
  }
  
  static void



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]