Questions tagged [socket]
For code which uses the Berkley Sockets API (specified by POSIX, and available on Windows too) to communicate with other processes using a network protocol.
327 questions
11 votes
4 answers
1k views
A simple server-client application in C
I am reading "The Linux Programming Interface" by Michael Kerrisk. I'm studying about sockets, and I made a simple application using sockets on the unix domain. I want to know if I'm using ...
2 votes
1 answer
103 views
Optimizing C System Design for Sensor Data Handling
I am developing a system in C for a device running Yocto Linux (Posix compatible, libc, etc.) on a microprocessor. The Yocto build is "quite generalized", as it's supposed to run several ...
7 votes
3 answers
2k views
Simple TCP port scanner
I’ve done port scanner program. It works well and accurate, but there is a problem. It’s SUPER slow. That’s how it looks: ...
8 votes
3 answers
737 views
Send arbitrary number of arbitrary length buffers in packets of fixed arbitrary size
Background: I am in earlier stages of implementing a standard on top of an existing 'backend' This standard requires that I send data in UDP packets of a size specified at runtime All packets must be ...
1 vote
2 answers
1k views
Multi-Client Socket Communication with Thread Pool in C++
I've been working on implementing a multi-client socket communication system with a thread pool in C++. The system comprises three main components: logger.h, socket.h, and thread.h, which handle ...
3 votes
1 answer
156 views
Winsock code for lockstep RTS game
Summary This is my core networking code for the lockstep RTS game that I am creating. Clients connect to a relay server via a TCP socket, and any packets sent to the relay server are forwarded to all ...
6 votes
1 answer
220 views
SNTPv4 server based on rfc 4330 in C++
Please review my SNTPv4 server based on rfc 4330 I tested running 3 instances of ntp-check.exe from Galleon systems and 1 instance of Microsoft w32tm - w32tm /stripchart /computer: No crash! This is a ...
8 votes
3 answers
1k views
struct sockaddr_storage initialization by network format string
I am writing a wrapper library for network functionality in C and wanted to let the user let the user initialize a struct sockaddr_storage with a format string. Format ist like: "proto:host:port/...