Search:

Type: Posts; User: symbiote

Page 1 of 2 1 2

Search: Search took 0.00 seconds.

  1. thank you! that was it. everything is working...

    thank you!
    that was it. everything is working now. i didn't expect any error state in such a simple case.
  2. "std::stringstream" unexpected behavior (simple example)

    hi Guys,

    i'm puzzled by the values i'm getting back from stringstream


    #include <sstream>
    #include <iostream>

    int main(int argc, char* argv[])
    {
  3. Replies
    3
    Views
    13,297

    hi and Welcome EyesOnly, on windows, winsock...

    hi and Welcome EyesOnly,

    on windows, winsock has a similar API.
    by connection i assume you mean you want to use TCP.

    one of the differences is, on windows you have to call:
    - WSAStartup()...
  4. Replies
    7
    Views
    1,918

    thanks for all the suggestions. i thought i'd...

    thanks for all the suggestions. i thought i'd close the topic properly because i already resolved this a while ago.

    the problem was that i didn't understand the tcp shutdown sequence. i was...
  5. Replies
    10
    Views
    1,436

    thanks for the advice. i have added exceptions....

    thanks for the advice.
    i have added exceptions.
    i think i'll do what dra and matsp said ( destroy and create a new object ). keeps things simple and reflects the winsock documentation.
    ...
  6. Replies
    10
    Views
    1,436

    yeah. i guess it's not the best example. i was...

    yeah. i guess it's not the best example. i was planning on adding error checking afterwards.
    actually i don't want to make a copy because that would mean an other object with the same value is left...
  7. Replies
    10
    Views
    1,436

    oh i'm not familiar implementing ref counting....

    oh i'm not familiar implementing ref counting. this is the code i was talking about

    mySocket.h


    #if !defined(_MYSOCKET_H)
    #define _MYSOCKET_H

    #include <string>
    #include <winsock2.h>
  8. Replies
    10
    Views
    1,436

    when i overload the assignment operator the...

    when i overload the assignment operator the destructor of the temporary object still gets called.

    if i change the data member of the assigning ( right hand ) object to a specific invalid value...
  9. Replies
    10
    Views
    1,436

    thanks, well basicly this object is in this...

    thanks,

    well basicly this object is in this case a data member of a class (by value).
    i prefer keeping things by value and i can see how you are right.

    i don't really want to drift off topic...
  10. Replies
    10
    Views
    1,436

    calling the contructor again

    hi Guys,

    i got a question...
    lets say i have a class "A" that can only be constructed with an int parameter

    like this:


    A objA(1);
  11. Replies
    7
    Views
    1,918

    hmm the tcp socket layer is telling me that my...

    hmm the tcp socket layer is telling me that my data got through when it didn't.
    the recieving application had already closed the connection and even exitted (properly).

    - how is everything...
  12. Replies
    7
    Views
    1,918

    hi brewbuck, as you mentioned, a third attemp...

    hi brewbuck,

    as you mentioned, a third attemp by the client gave an error ( 10053 - WSAECONNABORTED )

    how am i supposed to know have figured out that the second attemp failed? ( adding...
  13. Replies
    7
    Views
    1,918

    hi trinli, a call to WSAGetLastError() which...

    hi trinli,

    a call to WSAGetLastError() which retrieves the winsock error returns 0
    ( this should mean, no error if i remember )

    i guess i could have expected that since send did not return -1...
  14. Replies
    7
    Views
    1,918

    uncertainty in tcp data arrival?

    i have been fidgeting with winsock tcp ( i created simple client and server applications with only a main function )

    (i know this isn't the code but i'm trying to get the idea across i can post...
  15. Replies
    2
    Views
    3,430

    in tcp with accept SOCKET accept( SOCKET...

    in tcp with accept



    SOCKET accept( SOCKET s, struct sockaddr FAR* addr, int FAR* addrlen );


    when i call:
  16. Replies
    2
    Views
    3,430

    recvfrom - fromlen parameter

    i have been fidgeting winsock's udp.

    the function recvfrom mainly:



    int recvfrom( SOCKET s, char FAR* buf, int len, int flags, struct sockaddr FAR* from, int FAR* fromlen );


    it has been...
  17. thanks for the replies. i almost forgot i asked...

    thanks for the replies.
    i almost forgot i asked this question.
    i wanted a class that must to be initialized.
    thanks edoceo. that's exactly what i was looking for.

    Greetings
  18. a data member that has no default contructor?

    hi Guys,

    i basicly want a class that has no default constructor as a data member of another class. something like this:



    class A
    {
    public:
    A( int x );
  19. Replies
    2
    Views
    6,759

    interesting. thanks again laserlight (problem...

    interesting.
    thanks again laserlight (problem solved)

    Greetings
  20. Replies
    7
    Views
    1,508

    thank you for your insight everyone! i think i...

    thank you for your insight everyone!
    i think i don't think i'll be passing primitive types by reference for reasons.

    Greetings
  21. Replies
    2
    Views
    6,759

    type casting object to int?

    hi Guys,

    well i have a small issue (i think). i have a class that only contains one variable and i was wondering if i could assign an object of this class, to a variable of the same type as it's...
  22. Replies
    7
    Views
    1,508

    thanks for the response Phyxashun, i see. ...

    thanks for the response Phyxashun,
    i see.

    what i'm wondering now is, whether there is a cost in passing an int by reference.
    - and if it exist, wheter it would be more or less than the copy of...
  23. Replies
    7
    Views
    1,508

    are "const int&" parameters useful?

    hi guys

    i was wondering if i should rigorously stick to passing by reference.

    i was wondering if someone knew what kind of effect passing a const int by reference would have? ( what about...
  24. Replies
    4
    Views
    3,853

    i've been experimenting with the winsock libray....

    i've been experimenting with the winsock libray. and i'm still new to it so bear with me.

    just an observation...
    isn't a call to listen always followed by a call accept?
    there must be a reason...
  25. Replies
    4
    Views
    3,853

    thanks baccardi

    thanks baccardi
Results 1 to 25 of 29
Page 1 of 2 1 2