How logicalerror1/x86_server works
This is a minimal x86-64 Linux HTTP server. Clients connect to a listening socket; the server accepts each connection and forks, with the child handling a GET or POST while the parent continues accepting. GET reads a requested file and returns its contents; POST extracts the request body and writes it to a file. The only source file is file.s; because no source excerpts were provided, relationships shown here are based on the README’s documented workflow.
Main entry points: file.s Accept and fork
Components 7
Connection handling
- Socket listener
file.s - Accept and fork
file.s
Request handling
- Request handler
file.s - GET handler
file.s - POST handler
file.s
File operations
- File storage
file.s
Other components
- HTTP clients
Connections 11
- Socket listener → Accept and fork: accepts connections
README.md - HTTP clients → Accept and fork: connects to
README.md - Accept and fork → Request handler: forks child for
README.md - Accept and fork → Socket listener: parent resumes
README.md - Request handler → GET handler: dispatches GET
README.md - Request handler → POST handler: dispatches POST
README.md - GET handler → File storage: opens and reads
README.md - File storage → GET handler: returns contents
README.md - GET handler → HTTP clients: sends file response
README.md - POST handler → File storage: creates and writes
README.md - POST handler → HTTP clients: sends success response
README.md