/[smeserver]/rpms/e-smith-base/sme9/e-smith-base-5.6.0-console.patch
ViewVC logotype

Contents of /rpms/e-smith-base/sme9/e-smith-base-5.6.0-console.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (show annotations) (download)
Sat Apr 5 18:13:17 2014 UTC (10 years, 7 months ago) by wellsi
Branch: MAIN
CVS Tags: e-smith-base-5_6_0-13_el6_sme, e-smith-base-5_6_0-36_el6_sme, e-smith-base-5_6_0-27_el6_sme, e-smith-base-5_6_0-22_el6_sme, e-smith-base-5_6_0-12_el6_sme, e-smith-base-5_6_0-33_el6_sme, e-smith-base-5_6_0-31_el6_sme, e-smith-base-5_6_0-10_el6_sme, e-smith-base-5_6_0-34_el6_sme, e-smith-base-5_6_0-16_el6_sme, e-smith-base-5_6_0-19_el6_sme, e-smith-base-5_6_0-28_el6_sme, e-smith-base-5_6_0-5_el6_sme, e-smith-base-5_6_0-11_el6_sme, e-smith-base-5_6_0-3_el6_sme, e-smith-base-5_6_0-25_el6_sme, e-smith-base-5_6_0-21_el6_sme, e-smith-base-5_6_0-30_el6_sme, e-smith-base-5_6_0-35_el6_sme, e-smith-base-5_6_0-6_el6_sme, e-smith-base--, e-smith-base-5_6_0-32_el6_sme, e-smith-base-5_6_0-8_el6_sme, e-smith-base-5_6_0-7_el6_sme, e-smith-base-5_6_0-4_el6_sme, e-smith-base-5_6_0-26_el6_sme, e-smith-base-5_6_0-9_el6_sme, e-smith-base-5_6_0-23_el6_sme, e-smith-base-5_6_0-20_el6_sme, e-smith-base-5_6_0-29_el6_sme, e-smith-base-5_6_0-24_el6_sme, e-smith-base-5_6_0-17_el6_sme, e-smith-base-5_6_0-15_el6_sme, e-smith-base-5_6_0-18_el6_sme, HEAD
* Sat Apr 5 2014 Ian Wells <esmith@wellsi.com> 5.6.0-3.sme
- Ensure console is run with taint checking [SME: 8311]
- Non-functional perl::Critic changes.

1 diff -ruN e-smith-base-5.6.0.old/root/sbin/e-smith/console e-smith-base-5.6.0/root/sbin/e-smith/console
2 --- e-smith-base-5.6.0.old/root/sbin/e-smith/console 2008-10-07 10:34:53.000000000 -0700
3 +++ e-smith-base-5.6.0/root/sbin/e-smith/console 2014-04-05 10:48:42.000000000 -0700
4 @@ -1,4 +1,4 @@
5 -#!/usr/bin/perl -w
6 +#!/usr/bin/perl -wT
7
8 #----------------------------------------------------------------------
9 # copyright (C) 1999-2006 Mitel Corporation
10 @@ -36,28 +36,28 @@
11
12 $ENV{TERM} = $termType if($termType);
13
14 -system("/bin/sh", "/etc/profile.d/lang.sh");
15 +system '/bin/sh', '/etc/profile.d/lang.sh';
16
17 my %menu2object = ();
18 my @args = ();
19 my @items = ();
20
21 -my $menu_dir = "/sbin/e-smith/console-menu-items";
22 +my $menu_dir = '/sbin/e-smith/console-menu-items';
23
24 -opendir(ITEMS, $menu_dir);
25 +opendir ITEMS, $menu_dir;
26
27 -while (defined(my $item = readdir(ITEMS)))
28 +while (defined (my $item = readdir ITEMS ))
29 {
30 next unless -f "$menu_dir/$item";
31
32 if ($item =~ /([\w\.]+)/)
33 {
34 - $item = $1;
35 + $item = $1;
36 }
37 else
38 {
39 - warn "Don't know what to do with $menu_dir/$item\n";
40 - next;
41 + warn "Don't know what to do with $menu_dir/$item\n";
42 + next;
43 }
44
45 my $obj = require "$menu_dir/$item";
46 @@ -73,9 +73,9 @@
47 {
48 next if ($item->order < 0);
49 push @args, $number . '.', gettext($item->name);
50 - $menu2object{$number++ . "."} = $item;
51 + $menu2object{$number++ . '.'} = $item;
52 }
53 -
54 +
55 my $quit = esmith::console::quitConsole->new;
56 while (1)
57 {
58 @@ -85,21 +85,21 @@
59
60 $db->reload;
61
62 - my $title = gettext("Server console");
63 - $title .= " (${SystemName}.${DomainName})";
64 + my $title = gettext('Server console');
65 + $title .= " (${SystemName}.${DomainName}) ";
66
67 - $title .= " " . gettext("** unsaved changes **")
68 + $title .= gettext('** unsaved changes **')
69 if ( $db->get_value('UnsavedChanges') eq 'yes' );
70
71 my ($rc, $choice) = $console->menu_page
72 (
73 title => $title,
74 text =>
75 - gettext("Welcome to the server console!") .
76 + gettext('Welcome to the server console!') .
77 "\n\n" .
78 - gettext("Use the Arrow and Tab keys to make your selection, then press Enter."),
79 + gettext('Use the Arrow and Tab keys to make your selection, then press Enter.'),
80 argsref => \@args,
81 - left => gettext("Exit"),
82 + left => gettext('Exit'),
83 );
84
85 $choice = ($rc == 0) ? $menu2object{$choice} : $quit;

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed