Quote:
Originally Posted by Warty
Code:
unsigned long win_resize_gadget_width = 18;
unsigned long win_resize_gadget_height = 11; // Default size
|
This is the problem!
Quote:
Code:
GetAttr ((unsigned long)IA_Width, (APTR)win_resize_image, (unsigned long*)&win_resize_gadget_width);
|
And casting to
unsigned long*
doesn't help much, when GetAttr() needs an
ULONG*
.
I found out that the exec/types.h header from NDK 3.2 uses C99 stdint.h to define the AmigaOS types like ULONG. In the past it was simply defined as unsigned long. Now ULONG is defined as:
Code:
typedef uint32_t ULONG; /* unsigned 32-bit quantity */
While vbcc defines uint32_t in stdint.h as:
Code:
typedef unsigned int uint32_t;
This explains the warning, because different types (for the compiler) are referenced. The fix is simple. Just use ULONG when you need ULONG.