26 #ifndef _PURPLE_INTERNAL_H_
27 #define _PURPLE_INTERNAL_H_
35 #include <net/sockios.h>
51 # define _(String) ((const char *)dgettext(PACKAGE, String))
53 # define N_(String) gettext_noop (String)
55 # define N_(String) (String)
59 # define N_(String) (String)
61 # define _(String) ((const char *)String)
63 # define ngettext(Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
64 # define dngettext(Domain, Singular, Plural, Number) ((Number == 1) ? ((const char *)Singular) : ((const char *)Plural))
75 #define BUF_LEN MSG_LEN
76 #define BUF_LONG BUF_LEN * 2
79 #include <sys/types.h>
98 #ifdef HAVE_LANGINFO_CODESET
104 #ifdef PURPLE_PLUGINS
111 # include <netinet/in.h>
112 # include <sys/socket.h>
113 # include <arpa/inet.h>
115 # include <sys/utsname.h>
121 #ifndef HOST_NAME_MAX
122 # define HOST_NAME_MAX 255
129 #include <glib/gstdio.h>
132 #include "win32dep.h"
136 #if SIZEOF_TIME_T == 4
137 # define PURPLE_TIME_T_MODIFIER "lu"
138 #elif SIZEOF_TIME_T == 8
139 # define PURPLE_TIME_T_MODIFIER "zu"
141 #error Unknown size of time_t
145 #include <glib-object.h>
150 #undef g_utf8_next_char
151 #define g_utf8_next_char(p) (char *)((p) + 1)
158 #define purple_strlcpy(dest, src) g_strlcpy(dest, src, sizeof(dest))
159 #define purple_strlcat(dest, src) g_strlcat(dest, src, sizeof(dest))
164 struct sockaddr_in in;
165 struct sockaddr_in6 in6;
166 struct sockaddr_storage storage;
169 #define PURPLE_WEBSITE "https://pidgin.im/"
170 #define PURPLE_DEVEL_WEBSITE "https://pidgin.im/development/"
181 _purple_buddy_icons_account_loaded_cb(
void);
186 _purple_buddy_icons_blist_loaded_cb(
void);
192 _purple_buddy_icon_set_old_icons_dir(
const char *dirname);
212 const char *password);
226 PurpleAccountUnregistrationCb cb,
void *user_data);
Compatibility for many glib versions.
void _purple_connection_new_unregister(PurpleAccount *account, const char *password, PurpleAccountUnregistrationCb cb, void *user_data)
Tries to unregister the account on the server.
gboolean _purple_network_set_common_socket_flags(int fd)
Sets most commonly used socket flags: O_NONBLOCK and FD_CLOEXEC.
void _purple_connection_new(PurpleAccount *account, gboolean regist, const char *password)
Creates a connection to the specified account and either connects or attempts to register a new accou...
void _purple_connection_destroy(PurpleConnection *gc)
Disconnects and destroys a PurpleConnection.
Structure representing an account.