Hi,
I have the following codes:
When I free ptr, is any memory leak here? since I force to change the data type from 'struct ABC*' to 'int*'.Code:struct ABC { int x; float y; int z; } ... struct ABC *abc = malloc( sizeof( struct ABC ) ); int *ptr = ( int* )abc; free( ptr );