[PATCH 6/8] test-stkutil: Add unit test for Get Inkey response encoding.

Gu, Yang yang.gu at intel.com
Mon May 10 20:01:43 PDT 2010


Hi Andrew, 

>+#define NO_DURATION { .interval = 0x00, }
>+#define NO_TEXT { .text = NULL, .yesno = FALSE, }

There is no need to define these as static variables will be initialized to zero automatically. We must guarentee zero means non-existence. 
If some meaningful initialization happens to be missed, later check would catch them. Hope this can save several lines of code;)


>+
>+static const unsigned char get_inkey_response_111[] = {
>+	0x81, 0x03, 0x01, 0x22, 0x00, 0x82, 0x02, 0x82,
>+	0x81, 0x83, 0x01, 0x00, 0x8d, 0x02, 0x04, 0x2b,

Regards,
-Yang


More information about the ofono mailing list