Http basic implementation in C