Search:

Type: Posts; User: sehang

Search: Search took 0.01 seconds.

  1. Thank you. I try it now.

    Thank you. I try it now.
  2. Client accidently close when the server crash

    The steps to test the problem
    1. Open TCP Server
    2. Open TCP Client
    3. TCP Client sends data to Server.
    4. Close TCP Server and the client also crash without any notification

    Second wonderful...
  3. Would you please give me some idea about single client and multiple servers

    Hi,

    I have a program which needs to connect multiple servers at the same time. The program has to collect data from each of servers and then make a decision regarding to the data received.
    ...
  4. How to use sigmask in order to make signals can be processed by a thread

    Hi,

    I have a UDP server and client program, and they must run within a program, so I decided two threads, one for UDP server and another for UDP client.

    The simple architecture is shown in...
  5. Replies
    9
    Views
    5,059

    Hi, I still have no idea what does 'A thread...

    Hi, I still have no idea what does 'A thread function returns a void* and takes a single void*.'.

    1.
    Is it means, I should use


    pthread_create( &thread1, NULL, &testRun, NULL) == 0
    ...
  6. Replies
    9
    Views
    5,059

    It properly about the function sigaction() with...

    It properly about the function sigaction() with threading, is does not work, why signal and threading is conflict here?
  7. Replies
    9
    Views
    5,059

    It still does not work! The following codes are...

    It still does not work! The following codes are modified, but no effect!


    static void* testRun () {
    TCP();
    pthread_exit(NULL);
    return NULL;
    }
  8. Replies
    9
    Views
    5,059

    What does incorrect signature means? Thanks.

    What does incorrect signature means? Thanks.
  9. Replies
    9
    Views
    5,059

    Sorry, I forgot put the code of forever loop at...

    Sorry, I forgot put the code of forever loop at the main function, it should be here; and I will try to modify the thread by using join.
  10. Replies
    9
    Views
    5,059

    Unable to create a UDP client from thread?

    I try to initial a UDP client from threading, but it doesn't work? why?


    These codes from the textbook


    #define ECHOMAX 255 /* Longest string to echo */
    #define TIMEOUT_SECS 2...
  11. Replies
    4
    Views
    1,921

    Thanks all of you!

    Thanks all of you!
  12. Replies
    4
    Views
    1,921

    The reason why I need this like that. I have...

    The reason why I need this like that.

    I have an array which is int** ptrList which stores all pointers of struct XXX. And this array stores different struct, so it can't use a generic type.

    And...
  13. Replies
    4
    Views
    1,921

    Any problem or memory leak here?

    Hi,

    I have the following codes:


    struct ABC {
    int x;
    float y;
    int z;
    }
Results 1 to 13 of 14