Git Product home page Git Product logo

Comments (6)

clue avatar clue commented on May 19, 2024

Thanks for reporting!

The example code essentially executes this under the hood:

$a = stream_socket_server('tcp://0.0.0.0:9988');
$b = stream_socket_server('tcp://[::]:9988');

Which emits the very same error.

If you omit the first server, then the second works just fine. It looks like this is intended behavior.

I hope this helps 👍

from socket.

maxxer avatar maxxer commented on May 19, 2024

If that's intended how to open a socket for both v6/v4?

from socket.

maxxer avatar maxxer commented on May 19, 2024

Maybe this is related?
https://bugs.php.net/bug.php?id=73307

from socket.

maxxer avatar maxxer commented on May 19, 2024

I'm on linux and indeed this happens to be true. Using just the IPv6 [::] address listens on both the stacks, because my ubuntu server has 0 in /proc/sys/net/ipv6/bindv6only

from socket.

clue avatar clue commented on May 19, 2024

Thanks for confirming this! 👍

I've just filed feature request #59 so you may eventually specify the ipv6_v6only context option 👍

from socket.

clue avatar clue commented on May 19, 2024

For the reference, #64 introduced the required socket context options, so you may want to check out the v0.4.6 release 👍

from socket.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.