Skip to content

Missing case IP_PKTINFO in lwip_getsockopt_impl() #10

Description

@allgaeu-tobias

In the lwip_getsockopt_impl() function, the following case is missing:

 switch (level) {
    case IPPROTO_IP:
      switch (optname) {
#if LWIP_NETBUF_RECVINFO
        case IP_PKTINFO:
          LWIP_SOCKOPT_CHECK_OPTLEN_CONN_PCB(sock, *optlen, int);
          if ((sock->conn->flags & NETCONN_FLAG_PKTINFO) != 0) {
            *(int*)optval = 1;
          }
          else {
            *(int*)optval = 0;
          }
          LWIP_DEBUGF(SOCKETS_DEBUG, ("lwip_getsockopt(%d, IPPROTO_IP, IP_PKTINFO) = %d\n",
                                      s, *(int *)optval));
          break;
#endif /* LWIP_NETBUF_RECVINFO */

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions