Problem with c structs and byte arrays...maybe?

BlitzMax Forums/BlitzMax Programming/Problem with c structs and byte arrays...maybe?

Hi,

I'm in the process of putting together a module that handles tablet/digitizer input in BlitzMax, and have encountered something weird.

I've converted the following C structure:
typedef struct tagLOGCONTEXT {
	char	lcName[40];
	UINT	lcOptions;
	UINT	lcStatus;
	UINT	lcLocks;
	UINT	lcMsgBase;
	UINT	lcDevice;
	UINT	lcPktRate;
etc...
Into this BMax code:
Type tagLOGCONTEXT
	Field lcName:Byte[40] 
	Field lcOptions:Int 
	Field lcStatus:Int 
	Field lcLocks:Int
	Field lcMsgBase:Int
	Field lcDevice:Int 
	Field lcPktRate:Int
etc.
Now this BMax type is passed to some C mumbo jumbo, but it doesn't work correctly. Apparently the lcName byte array is of a wrong size. If I however replace it with 10 Ints it's working perfectly.

Took me the best of 4 hours to figure that out.

Is it a bug, or me being dumb?