lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [bug #20147] getsockopt() with SO_ERROR option


From: Frédéric Bernon
Subject: [lwip-devel] [bug #20147] getsockopt() with SO_ERROR option
Date: Mon, 11 Jun 2007 14:40:46 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.8.1.4) Gecko/20070515 Firefox/2.0.0.4

Follow-up Comment #1, bug #20147 (project lwip):

I think that conn->err is set to an error value (I suppose that err_tcp in
api_msg.c is called, put a trace here to be sure).

But sock->err is not change until next send, recv, etc...

Perhaps you can test to patch sockets.c like this:

    case SO_ERROR:
      if (sock->err==0) {
        sock_set_errno(sock, err_to_errno(conn->err)); /*PATCH*/
      }
      *(int *)optval = sock->err;
      sock->err = 0;

Like this, you should keep the first error. Tell me if you got the trace in
err_tcp, and if just patch is good for you...


    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?20147>

_______________________________________________
  Message posté via/par Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]