This is a very simple HTTP server for Unix, using fork(). It's very easy to use
- include header
httpd.h - write your route method, handling requests.
- call
serve_forever("12913")to start serving on port 12913
| /******************** | |
| * Exemplo maluco por Luiz Felipe. | |
| * | |
| * https://github.com/Silva97 | |
| ********************/ | |
| #include <stdio.h> | |
| #define UCHARPTR (unsigned char *) |
| /******************** | |
| * Exemplo de replace em C. | |
| * Por Luiz Felipe. | |
| * https://github.com/Silva97 | |
| ********************/ | |
| #include <stdio.h> | |
| #include <string.h> | |
| int replace(char *text, char *word, char *new); |
| /******************** | |
| * Developed by Luiz Felipe. | |
| * | |
| * GitHub: https://github.com/Silva97 | |
| * Facebook: https://www.facebook.com/B4.0E.B0.48.CD.10.B0.69.CD.10.C3 | |
| ********************/ | |
| #include <stdio.h> | |
| #include <stdarg.h> | |
| #include <limits.h> |
| /* | |
| * ************************************************** | |
| * mouseHandler: | |
| * Handler de mouse. | |
| * | |
| * *Importante: | |
| * Se estamos aqui é porque os dados disponíveis no controlador 8042 | |
| * pertencem ao mouse. | |
| * @todo: Essa rotina não pertence ao line discipline. | |
| * |
| /* C¢digo para o Borland C++ 3.1. | |
| coloquei delays de 1us entre escritas/leituras para o KBDC. | |
| coloquei verificação de acknowledge depois de mouse_writes. | |
| Ainda travando | |
| OK! Tio Fred estamos lidando com dispositivos seriais, na verade dois dispositivos partilhando o mesmo Chip, | |
| sabes o aquão trasçueiros eles são. |
| int main (){ | |
| //This is a test. | |
| return (int) 0; | |
| }; |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #include <string.h> | |
| #include <ctype.h> | |
| #include <stdint.h> | |
| #include <sys/socket.h> | |
| #include <sys/types.h> | |
| #include <linux/if_ether.h> | |
| #include <arpa/inet.h> |
| // Calculo de tabela verdade para formulas representadas | |
| // com arvores sintaticas. | |
| #include <stdio.h> | |
| #include <stdlib.h> | |
| #define TRUE 1 | |
| #define FALSE 0 | |
| // macro para calcular o valor da implicacao |
| /* A tiny BASIC interpreter */ | |
| #include <string.h> | |
| #include <stdio.h> | |
| #include <setjmp.h> | |
| #include <math.h> | |
| #include <ctype.h> | |
| #include <stdlib.h> | |
| #define NUM_LAB 100 |