File Coverage

gunzip.xs
Criterion Covered Total %
statement 2 4 50.0
branch 3 10 30.0
condition n/a
subroutine n/a
pod n/a
total 5 14 35.7


line stmt bran cond sub pod time code
1             /* Copyright 2007, 2008, 2009, 2010, 2011 Kevin Ryde
2              
3             This file is part of Filter-gunzip.
4              
5             Filter-gunzip is free software; you can redistribute it and/or modify it
6             under the terms of the GNU General Public License as published by the
7             Free Software Foundation; either version 3, or (at your option) any later
8             version.
9              
10             Filter-gunzip is distributed in the hope that it will be useful, but
11             WITHOUT ANY WARRANTY; without even the implied warranty of
12             MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
13             Public License for more details.
14              
15             You should have received a copy of the GNU General Public License along
16             with Filter-gunzip. If not, see . */
17              
18             #include "EXTERN.h"
19             #include "perl.h"
20             #include "XSUB.h"
21              
22             #define NEED_PL_parser
23             #include "ppport.h"
24              
25             MODULE = Filter::gunzip PACKAGE = Filter::gunzip
26              
27             SV *
28             _rsfp_filters ()
29             CODE:
30             /* printf ("%p\n", PL_parser); */
31 1 50         if (PL_parser && PL_rsfp_filters) {
    50          
    50          
32             /* printf ("%p\n", PL_rsfp_filters); */
33 0 0         RETVAL = newRV_inc ((SV *) PL_rsfp_filters);
34             } else {
35 1           RETVAL = &PL_sv_undef;
36             }
37             OUTPUT:
38             RETVAL
39              
40             PerlIO *
41             _rsfp ()
42             CODE:
43             /* PL_parser != NULL is meant to be checked by first calling
44             _rsfp_filters() */
45             /* printf ("%p\n", PL_rsfp); */
46 0 0         RETVAL = PL_rsfp;
47             OUTPUT:
48             RETVAL