mirror of
https://github.com/irssi/irssi.git
synced 2026-08-20 00:52:30 +02:00
perl changes - values() method doesn't exist anymore, instead of
$server->values()->{...} you now use directly $server->{...}
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@972 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
a99e93ef5d
commit
e95f309b50
22 changed files with 412 additions and 326 deletions
|
|
@ -32,23 +32,24 @@ MODULE = Irssi PACKAGE = Irssi::Rawlog PREFIX = rawlog_
|
|||
#*******************************
|
||||
|
||||
void
|
||||
values(rawlog)
|
||||
init(rawlog)
|
||||
Irssi::Rawlog rawlog
|
||||
PREINIT:
|
||||
HV *hv;
|
||||
AV *av;
|
||||
GSList *tmp;
|
||||
PPCODE:
|
||||
hv = newHV();
|
||||
hv_store(hv, "logging", 7, newSViv(rawlog->logging), 0);
|
||||
hv_store(hv, "nlines", 6, newSViv(rawlog->nlines), 0);
|
||||
CODE:
|
||||
hv = hvref(ST(0));
|
||||
if (hv != NULL) {
|
||||
hv_store(hv, "logging", 7, newSViv(rawlog->logging), 0);
|
||||
hv_store(hv, "nlines", 6, newSViv(rawlog->nlines), 0);
|
||||
|
||||
av = newAV();
|
||||
for (tmp = rawlog->lines; tmp != NULL; tmp = tmp->next) {
|
||||
av_push(av, new_pv(tmp->data));
|
||||
av = newAV();
|
||||
for (tmp = rawlog->lines; tmp != NULL; tmp = tmp->next) {
|
||||
av_push(av, new_pv(tmp->data));
|
||||
}
|
||||
hv_store(hv, "lines", 5, newRV_noinc((SV*)av), 0);
|
||||
}
|
||||
hv_store(hv, "lines", 5, newRV_noinc((SV*)av), 0);
|
||||
XPUSHs(sv_2mortal(newRV_noinc((SV*)hv)));
|
||||
|
||||
void
|
||||
rawlog_destroy(rawlog)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue