did you try:
int i=0; int ch=recv(new_socket,(void*)&i,sizeof(int),0); printf("Value of a is :%d\n", i);
thanx programmersbook ,it worked !!
first of all sorry,as instead of posting this ques in C-Forum i posted in C++ ...
i cant understand what is wrong in my approach of receiving the datas in the recv(),as i declare one void pointer and typecast it to approp pointer before dereferencing and it worked for quite a no of times and then it was not workin..
so,is my way of getting datas using pointers is wrong?
if i go by ur way, can u plz xplain how come "&i" (where i is a local variable in server code) get the value from client side or how value is passed from client's send() to server's recv().
thanx !!