From 01f445ee06bc3f303d4e7d8fb00938220adbf618 Mon Sep 17 00:00:00 2001 From: MikalaiR Date: Tue, 7 Apr 2015 13:11:14 +0000 Subject: SkypeWeb: Chats support part 1. git-svn-id: http://svn.miranda-ng.org/main/trunk@12649 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/SkypeWeb/src/skype_utils.cpp | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'protocols/SkypeWeb/src/skype_utils.cpp') diff --git a/protocols/SkypeWeb/src/skype_utils.cpp b/protocols/SkypeWeb/src/skype_utils.cpp index d9c1501b0b..d86b745480 100644 --- a/protocols/SkypeWeb/src/skype_utils.cpp +++ b/protocols/SkypeWeb/src/skype_utils.cpp @@ -195,6 +195,27 @@ char *CSkypeProto::SelfUrlToName(const char *url) return tempname; } +char *CSkypeProto::ChatUrlToName(const char *url) +{ + char *tempname = NULL; + const char *start, *end; + start = strstr(url, "/19:"); + + if (!start) + return NULL; + start = start + 4; + if ((end = strchr(start, '/'))) + { + mir_free(tempname); + tempname = mir_strndup(start, end - start); + return tempname; + } + mir_free(tempname); + tempname = mir_strdup(start); + + return tempname; +} + char *CSkypeProto::GetServerFromUrl(const char *url) { char *tempname = NULL; -- cgit v1.2.3