pidgin/purple-plugin-pack

Add the turtles target to keep the foot clan at bay
default tip
13 months ago, Gary Kramlich
63ad7e4f10b4
Add the turtles target to keep the foot clan at bay

Testing Done:
Ran `ninja turtles` and verified it worked correctly.

Reviewed at https://reviews.imfreedom.org/r/2409/
/*
* libomegle
*
* libomegle is the property of its developers. See the COPYRIGHT file
* for more details.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef LIBOMEGLE_H
#define LIBOMEGLE_H
#include "../common/pp_internal.h"
#define OMEGLE_PLUGIN_ID "prpl-bigbrownchunx-omegle"
#include <glib.h>
#include <errno.h>
#include <string.h>
#include <sys/types.h>
#include <unistd.h>
#ifndef G_GNUC_NULL_TERMINATED
# if __GNUC__ >= 4
# define G_GNUC_NULL_TERMINATED __attribute__((__sentinel__))
# else
# define G_GNUC_NULL_TERMINATED
# endif /* __GNUC__ >= 4 */
#endif /* G_GNUC_NULL_TERMINATED */
#ifdef _WIN32
# include "win32dep.h"
# define dlopen(a,b) LoadLibrary(a)
# define RTLD_LAZY
# define dlsym(a,b) GetProcAddress(a,b)
# define dlclose(a) FreeLibrary(a)
#else
# include <arpa/inet.h>
# include <dlfcn.h>
# include <netinet/in.h>
# include <sys/socket.h>
#endif
#ifndef PURPLE_PLUGINS
# define PURPLE_PLUGINS
#endif
#include "accountopt.h"
#include "connection.h"
#include "debug.h"
#include "dnsquery.h"
#include "proxy.h"
#include "prpl.h"
#include "request.h"
#include "sslconn.h"
#include "version.h"
#if GLIB_MAJOR_VERSION >= 2 && GLIB_MINOR_VERSION >= 12
# define atoll(a) g_ascii_strtoll(a, NULL, 0)
#endif
#define OM_MAX_MSG_RETRY 2
typedef struct _OmegleAccount OmegleAccount;
typedef struct _OmegleBuddy OmegleBuddy;
typedef void (*OmegleProxyCallbackFunc)(OmegleAccount *oma, gchar *data, gsize data_len, gpointer user_data);
struct _OmegleAccount {
PurpleAccount *account;
PurpleConnection *pc;
GSList *conns; /**< A list of all active OmegleConnections */
GSList *dns_queries;
GHashTable *cookie_table;
GHashTable *hostname_ip_cache;
};
#endif /* LIBOMEGLE_H */