mirror of
https://github.com/zeromq/cppzmq.git
synced 2025-10-19 12:42:32 +02:00
Compile and update the examples in the README
This commit is contained in:
9
examples/hello_world.cpp
Normal file
9
examples/hello_world.cpp
Normal file
@@ -0,0 +1,9 @@
|
||||
#include <zmq.hpp>
|
||||
|
||||
int main()
|
||||
{
|
||||
zmq::context_t ctx;
|
||||
zmq::socket_t sock(ctx, zmq::socket_type::push);
|
||||
sock.bind("inproc://test");
|
||||
sock.send(zmq::str_buffer("Hello, world"), zmq::send_flags::dontwait);
|
||||
}
|
Reference in New Issue
Block a user