diff options
| author | ame <[email protected]> | 2025-08-01 19:27:34 -0500 |
|---|---|---|
| committer | ame <[email protected]> | 2025-08-01 19:27:34 -0500 |
| commit | 6b0cda77a3e04e4fb3024b21bb648b6bf9f62568 (patch) | |
| tree | 4075adb605d0bee3a5535134e27aec75736b9305 | |
| parent | 9ee19b1e0af44f48f39bd6ce57a0cb85eb1147ad (diff) | |
send user-agent
| -rw-r--r-- | src/net.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -546,7 +546,7 @@ int l_srequest(lua_State* L){ //char* req = "GET / HTTP/1.1\nHost: amyy.cc\nConnection: Close\n\n";
char* request = calloc(cont_len + header->len + strlen(host) + strlen(path) + 512, sizeof * request);
- sprintf(request, "%s %s HTTP/1.1\r\nHost: %s\r\nConnection: Close%s\r\n\r\n%s", action, path, host, header->c, cont);
+ sprintf(request, "%s %s HTTP/1.1\r\nUser-Agent: lullaby/"MAJOR_VERSION"\r\nHost: %s\r\nConnection: Close%s\r\n\r\n%s", action, path, host, header->c, cont);
//printf("%s\n", request);
str_free(header);
|
