public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
[parent not found: <4a719afc.9f13f30a.2eaa.ffffa236SMTPIN_ADDED@mx.google.com>]
* [LTP] [PATCH] Make the test result codes a real bitfield again
@ 2009-07-30  9:57 Jiri Palecek
  0 siblings, 0 replies; 5+ messages in thread
From: Jiri Palecek @ 2009-07-30  9:57 UTC (permalink / raw)
  Cc: ltp-list

Hello,

the commit "extend the test result to a bit field so we can extend the output further" from July 20th unfortunately changes the code, that was previously a bitfield, to a non-bitfield. This causes FAILED tests to return erroneously 0.

This patch changes the test result codes to be individual bits in the bitfield (effectively reverting  a small part of aforementioned patch).

Regards
    Jiri Palecek

---
 include/test.h |   12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/include/test.h b/include/test.h
index 5c325b3..4d9803a 100644
--- a/include/test.h
+++ b/include/test.h
@@ -44,15 +44,15 @@
 
 #include "compiler.h"
 
-/* Use low 4 bits to encode test type */
-#define TTYPE_MASK 0xf
+/* Use low 6 bits to encode test type */
+#define TTYPE_MASK 0x3f
 #define TPASS      0    /* Test passed flag */
 #define TFAIL      1    /* Test failed flag */
 #define TBROK      2    /* Test broken flag */
-#define TWARN      3    /* Test warning flag */
-#define TRETR      4    /* Test retire flag */
-#define TINFO      5    /* Test information flag */
-#define TCONF      6    /* Test not appropriate for configuration flag */
+#define TWARN      4    /* Test warning flag */
+#define TRETR      8    /* Test retire flag */
+#define TINFO      16   /* Test information flag */
+#define TCONF      32   /* Test not appropriate for configuration flag */
 #define TTYPE_RESULT(ttype) ((ttype) & TTYPE_MASK)
 
 #define TERRNO     0x100   /* Append errno information to output */
-- 
1.6.3.3




------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

end of thread, other threads:[~2009-08-13  9:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <200907301305.n6UD5G7F023361@e32.co.us.ibm.com>
2009-08-03 11:20 ` [LTP] [PATCH] Make the test result codes a real bitfield again Subrata Modak
2009-08-03 14:42   ` Michal Simek
2009-08-04 12:08     ` Subrata Modak
     [not found] <4a719afc.9f13f30a.2eaa.ffffa236SMTPIN_ADDED@mx.google.com>
2009-08-13  9:57 ` Mike Frysinger
2009-07-30  9:57 Jiri Palecek

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