summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/perl/common/Core.xs10
-rw-r--r--src/perl/irc/Dcc.xs8
-rw-r--r--src/perl/irc/Modes.xs16
-rw-r--r--src/perl/irc/Server.xs8
-rw-r--r--src/perl/ui/Formats.xs8
5 files changed, 43 insertions, 7 deletions
diff --git a/src/perl/common/Core.xs b/src/perl/common/Core.xs
index d6fdfdd8..da29b521 100644
--- a/src/perl/common/Core.xs
+++ b/src/perl/common/Core.xs
@@ -445,9 +445,15 @@ int
level2bits(str)
char *str
-char *
+void
bits2level(bits)
int bits
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = bits2level(bits);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
int
combine_level(level, str)
@@ -513,7 +519,7 @@ void
pidwait_remove(pid)
int pid
-char *
+void
parse_special(cmd, data="", flags=0)
char *cmd
char *data
diff --git a/src/perl/irc/Dcc.xs b/src/perl/irc/Dcc.xs
index 657783a7..8c906a19 100644
--- a/src/perl/irc/Dcc.xs
+++ b/src/perl/irc/Dcc.xs
@@ -58,9 +58,15 @@ dcc_ctcp_message(server, target, chat, notice, msg)
int notice
char *msg
-char *
+void
dcc_get_download_path(fname)
char *fname
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = dcc_get_download_path(fname);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
#*******************************
MODULE = Irssi::Irc::Dcc PACKAGE = Irssi::Irc::Dcc PREFIX = dcc_
diff --git a/src/perl/irc/Modes.xs b/src/perl/irc/Modes.xs
index 5dcb3389..723930fb 100644
--- a/src/perl/irc/Modes.xs
+++ b/src/perl/irc/Modes.xs
@@ -3,21 +3,33 @@
MODULE = Irssi::Irc::Modes PACKAGE = Irssi::Irc
PROTOTYPES: ENABLE
-char *
+void
modes_join(old, mode, channel)
char *old
char *mode
int channel
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = modes_join(old, mode, channel);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
#*******************************
MODULE = Irssi::Irc::Modes PACKAGE = Irssi::Irc::Channel PREFIX = channel_
#*******************************
-char *
+void
ban_get_mask(channel, nick, ban_type)
Irssi::Irc::Channel channel
char *nick
int ban_type
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = ban_get_mask(channel, nick, ban_type);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
Irssi::Irc::Ban
banlist_add(channel, ban, nick, time)
diff --git a/src/perl/irc/Server.xs b/src/perl/irc/Server.xs
index 0cbcad8e..dfe88f65 100644
--- a/src/perl/irc/Server.xs
+++ b/src/perl/irc/Server.xs
@@ -45,9 +45,15 @@ static GSList *event_hash2list(HV *hv)
MODULE = Irssi::Irc::Server PACKAGE = Irssi::Irc::Server PREFIX = irc_server_
PROTOTYPES: ENABLE
-char *
+void
irc_server_get_channels(server)
Irssi::Irc::Server server
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = irc_server_get_channels(server);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
void
send_raw(server, cmd)
diff --git a/src/perl/ui/Formats.xs b/src/perl/ui/Formats.xs
index d016f07d..f7a5414b 100644
--- a/src/perl/ui/Formats.xs
+++ b/src/perl/ui/Formats.xs
@@ -26,9 +26,15 @@ format_real_length(str, len)
char *str
int len
-char *
+void
strip_codes(input)
char *input
+PREINIT:
+ char *ret;
+PPCODE:
+ ret = strip_codes(input);
+ xPUSHs(sv_2mortal(new_pv(ret)));
+ g_free(ret);
void
format_get_text(window, module, server, target, formatnum, ...)