Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* [RFC] logic change in m2-valprint.c
@ 2007-06-29  0:37 msnyder
  2007-07-01 15:49 ` Daniel Jacobowitz
  0 siblings, 1 reply; 11+ messages in thread
From: msnyder @ 2007-06-29  0:37 UTC (permalink / raw)
  To: gdb-patches; +Cc: gaius

[-- Attachment #1: Type: text/plain, Size: 267 bytes --]

I'm really not sure about this, call it a shot in the dark.

The logic doesn't make sense as it is (the condition can't be true),
so I figured maybe the conditional had been reversed by mistake.

Either that, or the two lines should be removed, 'cause they're dead.


[-- Attachment #2: m2.txt --]
[-- Type: text/plain, Size: 897 bytes --]

2007-06-28  Michael Snyder  <msnyder@access-company.com>

	* m2-valprint.c (m2_print_long_set): Logical condition reversed
	(Coverity).

Index: m2-valprint.c
===================================================================
RCS file: /cvs/src/src/gdb/m2-valprint.c,v
retrieving revision 1.12
diff -p -r1.12 m2-valprint.c
*** m2-valprint.c	9 Jan 2007 17:58:51 -0000	1.12
--- m2-valprint.c	29 Jun 2007 00:25:56 -0000
*************** m2_print_long_set (struct type *type, co
*** 132,138 ****
  	      previous_high = i;
  	      if (! element_seen)
  		{
! 		  if (! empty_set)
  		    fprintf_filtered (stream, ", ");
  		  print_type_scalar (target, i, stream);
  		  empty_set    = 0;
--- 132,138 ----
  	      previous_high = i;
  	      if (! element_seen)
  		{
! 		  if (empty_set)
  		    fprintf_filtered (stream, ", ");
  		  print_type_scalar (target, i, stream);
  		  empty_set    = 0;

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2007-07-03 19:26 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-29  0:37 [RFC] logic change in m2-valprint.c msnyder
2007-07-01 15:49 ` Daniel Jacobowitz
2007-07-01 15:54   ` Michael Snyder
2007-07-01 16:03     ` Daniel Jacobowitz
2007-07-03  0:05       ` msnyder
2007-07-03  1:12         ` Daniel Jacobowitz
2007-07-03  1:21           ` msnyder
2007-07-03  1:24             ` Daniel Jacobowitz
2007-07-03  1:40               ` msnyder
2007-07-03  7:42           ` Mark Kettenis
2007-07-03 19:26             ` Jim Blandy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox