iamandi / nanopb

Automatically exported from code.google.com/p/nanopb
zlib License
0 stars 0 forks source link

Example fails to compile on 64-bit Linux with GCC 4.6: cast from pointer to integer of different size #9

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

$ make -C example
...
common.c: In function ‘write_callback’:
common.c:13:14: error: cast from pointer to integer of different size 
[-Werror=pointer-to-int-cast]
...
$

GCC complains about void* <-> int conversion. Converting through intptr_t fixes 
this problem.

nanopb 0.1.2

Original issue reported on code.google.com by mikhail....@gmail.com on 19 May 2012 at 6:08

GoogleCodeExporter commented 9 years ago
Fixed:
http://code.google.com/p/nanopb/source/detail?r=b94329088691538004f745a28e568d5a
e1fba456

Original comment by Petteri.Aimonen on 19 May 2012 at 6:18