junity233 / web.c Goto Github PK
View Code? Open in Web Editor NEWA lightweight http server framework written in C Language
License: GNU General Public License v2.0
A lightweight http server framework written in C Language
License: GNU General Public License v2.0
在编译项目时提示缺少头文件:
earthmessenger@DESKTOP-7K22VIM:~/cpp/Web.c$ make
gcc -Wall -D_DEBUG -g3 -pthread -I llhttp/include -I C-Thread-Pool -I src -c -o src/web.o src/web.c
src/web.c:14:10: fatal error: thpool.h: No such file or directory
14 | #include "thpool.h"
| ^~~~~~~~~~
compilation terminated.
make: *** [<builtin>: src/web.o] Error 1
毕竟文件 io 最慢了。
定义改成 void ReadFileToBuffer(BinaryBuffer* buffer,const char* file, const bool use_cache);
,其中 use_cache
可表示是否使用缓存。
用一颗 map
同款红黑树维护 url 到文件内容的映射。
用 clear_cache()
来清空缓存(把缓存管理什么的甩给用户)。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.