File: perl-warnings

package info (click to toggle)
usemod-wiki 1.0.5-1%2Bdeb7u1
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 1,548 kB
  • sloc: perl: 4,835; sh: 55; makefile: 29
file content (28 lines) | stat: -rw-r--r-- 921 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
--- a/wiki.pl
+++ b/wiki.pl
@@ -1068,7 +1068,7 @@ sub GetHistoryLine {
   $minor = '<i>' . T('(edit)') . '</i> '  if ($revtext{'minor'});
   $expirets = $Now - ($KeepDays * 24 * 60 * 60);
   if ($UseDiff) {
-    my ($c1, $c2);
+    my ($c1, $c2) = ("", "");
     $c1 = 'checked="checked"' if 1 == $row;
     $c2 = 'checked="checked"' if 0 == $row;
     $html .= "<tr><td align='center'><input type='radio' "
@@ -1651,6 +1651,7 @@ sub WikiToHTML {
     pop @HeadingNumbers;
     $TableOfContents .= "</dd></dl>\n\n";
   }
+  $TableOfContents ||= "";
   $pageText =~ s/&lt;toc&gt;/$TableOfContents/gi;
   if ($LateRules ne '') {
     $pageText = &EvalLocalRules($LateRules, $pageText, 0);
@@ -2150,7 +2151,7 @@ sub SplitUrlPunct {
     ($punct) = ($url =~ /([^a-zA-Z0-9\/\xc0-\xff]+)$/);
     $url =~ s/([^a-zA-Z0-9\/\xc0-\xff]+)$//;
   }
-  return ($url, $punct);
+  return ($url, $punct || "");
 }
 
 sub StripUrlPunct {