thank you darryl
Type: Posts; User: zee
thank you darryl
Also can you explain how u found the solution there?
i did not figure that out,
thank you very much
Thanx!
where can i disable this unicode crap?
Hello, I have the following code:
#include <windows.h>
int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow)
{
MessageBox(NULL,...
thanx a bunch
Has anyone had experience with a production level UDP game server protocol?
I was hoping for some help on how to proceed about this. What concerns and what issues should i consider. Security...
yeah itsme i am trying to learn the standards, lol this is my first time doing C :( . I will try out hte suggestion asap and get back to you guys, thanks for the ongoing help.
oh and about the...
but did u see the output i get from the programs i posted? can u explain that?
Hello ladies and gents,
I have these two files, server and client codes, they run fine but i just can not get the server to properly send file contents to the client. I am just sending a string...
heh dummmie me,
i got the output fixed, i did another read since i did 2 writes
and now the file is also printed
client does this now:
write(sockfd, argv[2], strlen(argv[2]));...
What about this?
int http_ok(char *buffer, FILE *local_file, int socket, char *time){
printf("Sending ok\n");
char header[] = "OK 200";
int header_length = sizeof(header);
...
but if you look at the output of the server,
Client said: GET ./forkserver.c HTTP/1.0
path is: ./forkserver.c
Sending ok
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
here is what the client is doing:
write(sockfd, argv[2], strlen(argv[2]));
printf("I have written to the socket.\r\n");
read(sockfd,buf,MAXDATASIZE);
buf[MAXDATASIZE] = '\0';...
It is almost the same as mine yet mine hanged and yours dosnt ??
well thank you quzah i fixed it by doing minor adjustments like urs. Thanks to itsme as well :D
i have another wierd problem:
...
hmm let me try to ask this differently,
how can i communicate between a server and client back and forth; with read and writes.
Can someone give me an example?
no need for all the connection...
Socket problem :(
Whenever i make a socket and use it for reading and writing, i have this problem,
i open one socket on the server and it reads from it ( and of course the client writes to it)...
oh nevermind, its working now,
thankkkkkkkkkkkkkkkkkkk you itsme!
wierd still does not work for me, i moved the declaration up and also added teh fflush still same problem :(
I tried to check if fopen returned a value < 0 but it does not. nad it sitll hangs in the same spot, strace gives me :
... , Writing to file now:
0xbfffdfc0, [16]) = ? ERESTARTSYS...
i tried that it still the same problem,
here is what the client program sends:
Writen(sockfd, "Sup?\n", 5);
printf("I have written to the socket.\n");
/* close the socket */
Helo ladies and gentleman,
I have this wierd problem i can not figure out,
i have a server and a client proggies, they both work fine on the connection part. The problem is:
when i write to...
thanks again itsme,
one more thing,
my server is supposed to send http requests,
do u know how that works?
my idea is that i have a tcp connection with the host and i just write "GET...
Another question,
i am using a wrapper function to do the socket(),
int Socket(int family, int type, int protocol)
{
int n;
wow that was fast,
thanx again!
itsme
hi guys i am trying to bind a name to a socket,
here is the bind chunk :
/* Bind the socket */
if (bind(sockfd, (struct sockaddr *)&my_addr,
sizeof(struct sockaddr)) == -1) {
...