On 25.02.2013 09:01, Patrik Flykt wrote:
Hi,
On Fri, 2013-02-22 at 15:31 +0200, Tomasz Bursztyka wrote:
+typedef enum {
+ DE_AUTHENTICATION_TYPE,
+ DE_NETWORK_KEY,
+ DE_SSID,
+ DE_MAX,
+ DE_UNKNOWN,
+} DEid;
+
+const struct data_elements DEs[] = {
+ { 0x1003, 2, TRUE },
+ { 0x1027, 64, FALSE },
+ { 0x1045, 32, FALSE },
+ {},
+};
In a later patch there is a function, that acesses DEs[] using the DEid
enum. If DEs[DE_UNKNOWN] is accessed, I'd suspect we get a segfault
here. Maybe define DE_UNKNOWN = DE_MAX, but also set the DE_* to
suitable integer values. And can the length be initialized with DE_MAX?
The struct should also be static here.
Cheers,
Jukka
_______________________________________________
connman mailing list
connman@connman.net
http://lists.connman.net/listinfo/connman