C++ compile error c2664 ZeroMemory -


why zeromemory(&socketaddress, sizeof(connection::socketaddress)); work, doesn't?

zeromemory(&connection::socketaddress, sizeof(connection::socketaddress)); 

i error: error c2664: 'memset' : cannot convert parameter 1 'sockaddr_in connection::* ' 'void *'

&connection::socketaddress member pointer. it's not pointer, way pointer particular member of class given pointer class. zeromemory can't accept because doesn't point real memory; needs more information (a pointer instance of class containing member) before can real pointer.

take @ this question more information member pointers.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

javascript - jQuery .height() return 0 when visible but non-0 when hidden -