$ git clone http://tcclient.ion.nu/tc_client.git
commit 4bb003dafc256161d30ca5794d71057bd984e338
Author: Alicia <...>
Date: Mon Dec 26 06:18:03 2016 +0100
Use tinychat.com instead of apl.tinychat.com (works around SSL/TLS issues on windows)
diff --git a/ChangeLog b/ChangeLog
index 0fc408d..dfdb76e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,5 @@
+0.41.1:
+Use tinychat.com instead of apl.tinychat.com (works around SSL/TLS issues on windows)
0.41:
Added some compatibility code for OSX.
Enabled compiling in a directory separate from the source directory.
diff --git a/Makefile b/Makefile
index 2a901fb..e9412f6 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
-VERSION=0.41
+VERSION=0.41.1
CFLAGS=-g3 -Wall -I. $(shell curl-config --cflags)
LDFLAGS=-g3
PREFIX=/usr/local
diff --git a/client.c b/client.c
index 0bd0b22..e0d574c 100644
--- a/client.c
+++ b/client.c
@@ -94,16 +94,16 @@ char* gethost(char *channel, char *password)
int urllen;
if(password)
{
- urllen=strlen("http://apl.tinychat.com/api/find.room/?site=&password=0")+strlen(channel)+strlen(sitearg)+strlen(password);
+ urllen=strlen("http://tinychat.com/api/find.room/?site=&password=0")+strlen(channel)+strlen(sitearg)+strlen(password);
}else{
- urllen=strlen("http://apl.tinychat.com/api/find.room/?site=0")+strlen(channel)+strlen(sitearg);
+ urllen=strlen("http://tinychat.com/api/find.room/?site=0")+strlen(channel)+strlen(sitearg);
}
char url[urllen];
if(password)
{
- sprintf(url, "http://apl.tinychat.com/api/find.room/%s?site=%s&password=%s", channel, sitearg, password);
+ sprintf(url, "http://tinychat.com/api/find.room/%s?site=%s&password=%s", channel, sitearg, password);
}else{
- sprintf(url, "http://apl.tinychat.com/api/find.room/%s?site=%s", channel, sitearg);
+ sprintf(url, "http://tinychat.com/api/find.room/%s?site=%s", channel, sitearg);
}
char* response=http_get(url, 0);
if(!response){exit(-1);}
@@ -141,8 +141,8 @@ char* gethost(char *channel, char *password)
char* getkey(int id, const char* channel)
{
- char url[snprintf(0,0, "http://apl.tinychat.com/api/captcha/check.php?guest%%5Fid=%i&room=%s%%5E%s", id, sitearg, channel)+1];
- sprintf(url, "http://apl.tinychat.com/api/captcha/check.php?guest%%5Fid=%i&room=%s%%5E%s", id, sitearg, channel);
+ char url[snprintf(0,0, "http://tinychat.com/api/captcha/check.php?guest%%5Fid=%i&room=%s%%5E%s", id, sitearg, channel)+1];
+ sprintf(url, "http://tinychat.com/api/captcha/check.php?guest%%5Fid=%i&room=%s%%5E%s", id, sitearg, channel);
char* response=http_get(url, 0);
char* key=strstr(response, "\"key\":\"");
@@ -185,8 +185,8 @@ char* getcookie(const char* channel)
char* getbroadcastkey(const char* channel, const char* nick, const char* bpassword)
{
unsigned int id=idlist_get(nick);
- char url[snprintf(0,0, "http://apl.tinychat.com/api/broadcast.pw?name=%s&site=%s&nick=%s&id=%u%s%s", channel, sitearg, nick, id, bpassword?"&password=":"", bpassword?bpassword:"")+1];
- sprintf(url, "http://apl.tinychat.com/api/broadcast.pw?name=%s&site=%s&nick=%s&id=%u%s%s", channel, sitearg, nick, id, bpassword?"&password=":"", bpassword?bpassword:"");
+ char url[snprintf(0,0, "http://tinychat.com/api/broadcast.pw?name=%s&site=%s&nick=%s&id=%u%s%s", channel, sitearg, nick, id, bpassword?"&password=":"", bpassword?bpassword:"")+1];
+ sprintf(url, "http://tinychat.com/api/broadcast.pw?name=%s&site=%s&nick=%s&id=%u%s%s", channel, sitearg, nick, id, bpassword?"&password=":"", bpassword?bpassword:"");
char* response=http_get(url, 0);
if(strstr(response, " result='PW'")){free(response); return 0;}
char* key=strstr(response, " token='");