Filename | /cygdrive/c/lo/libo-master/instsetoo_native/util/C:/lo/libo-master/solenv/bin/modules/installer/exiter.pm |
Statements | Executed 15 statements in 4.23ms |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
1 | 1 | 1 | 17.0ms | 81.0ms | BEGIN@37 | installer::exiter::
1 | 1 | 1 | 11.1ms | 17.0ms | BEGIN@36 | installer::exiter::
1 | 1 | 1 | 1.67ms | 11.1ms | BEGIN@33 | installer::exiter::
1 | 1 | 1 | 405µs | 414µs | BEGIN@30 | installer::exiter::
1 | 1 | 1 | 21µs | 39µs | BEGIN@31 | installer::exiter::
1 | 1 | 1 | 16µs | 18µs | BEGIN@34 | installer::exiter::
1 | 1 | 1 | 15µs | 49µs | BEGIN@35 | installer::exiter::
0 | 0 | 0 | 0s | 0s | exit_program | installer::exiter::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | #************************************************************************* | ||||
2 | # | ||||
3 | # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. | ||||
4 | # | ||||
5 | # Copyright 2000, 2010 Oracle and/or its affiliates. | ||||
6 | # | ||||
7 | # OpenOffice.org - a multi-platform office productivity suite | ||||
8 | # | ||||
9 | # This file is part of OpenOffice.org. | ||||
10 | # | ||||
11 | # OpenOffice.org is free software: you can redistribute it and/or modify | ||||
12 | # it under the terms of the GNU Lesser General Public License version 3 | ||||
13 | # only, as published by the Free Software Foundation. | ||||
14 | # | ||||
15 | # OpenOffice.org is distributed in the hope that it will be useful, | ||||
16 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||||
17 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||||
18 | # GNU Lesser General Public License version 3 for more details | ||||
19 | # (a copy is included in the LICENSE file that accompanied this code). | ||||
20 | # | ||||
21 | # You should have received a copy of the GNU Lesser General Public License | ||||
22 | # version 3 along with OpenOffice.org. If not, see | ||||
23 | # <http://www.openoffice.org/license.html> | ||||
24 | # for a copy of the LGPLv3 License. | ||||
25 | # | ||||
26 | #************************************************************************* | ||||
27 | |||||
28 | package installer::exiter; | ||||
29 | |||||
30 | 2 | 62µs | 2 | 423µs | # spent 414µs (405+9) within installer::exiter::BEGIN@30 which was called:
# once (405µs+9µs) by installer::archivefiles::BEGIN@31 at line 30 # spent 414µs making 1 call to installer::exiter::BEGIN@30
# spent 9µs making 1 call to strict::import |
31 | 2 | 62µs | 2 | 58µs | # spent 39µs (21+18) within installer::exiter::BEGIN@31 which was called:
# once (21µs+18µs) by installer::archivefiles::BEGIN@31 at line 31 # spent 39µs making 1 call to installer::exiter::BEGIN@31
# spent 18µs making 1 call to warnings::import |
32 | |||||
33 | 2 | 1.05ms | 2 | 11.1ms | # spent 11.1ms (1.67+9.46) within installer::exiter::BEGIN@33 which was called:
# once (1.67ms+9.46ms) by installer::archivefiles::BEGIN@31 at line 33 # spent 11.1ms making 1 call to installer::exiter::BEGIN@33
# spent 5µs making 1 call to UNIVERSAL::import |
34 | 2 | 54µs | 2 | 20µs | # spent 18µs (16+2) within installer::exiter::BEGIN@34 which was called:
# once (16µs+2µs) by installer::archivefiles::BEGIN@31 at line 34 # spent 18µs making 1 call to installer::exiter::BEGIN@34
# spent 2µs making 1 call to UNIVERSAL::import |
35 | 2 | 55µs | 2 | 84µs | # spent 49µs (15+34) within installer::exiter::BEGIN@35 which was called:
# once (15µs+34µs) by installer::archivefiles::BEGIN@31 at line 35 # spent 49µs making 1 call to installer::exiter::BEGIN@35
# spent 34µs making 1 call to Exporter::import |
36 | 2 | 1.20ms | 2 | 17.0ms | # spent 17.0ms (11.1+5.90) within installer::exiter::BEGIN@36 which was called:
# once (11.1ms+5.90ms) by installer::archivefiles::BEGIN@31 at line 36 # spent 17.0ms making 1 call to installer::exiter::BEGIN@36
# spent 7µs making 1 call to UNIVERSAL::import |
37 | 2 | 1.75ms | 2 | 81.0ms | # spent 81.0ms (17.0+64.0) within installer::exiter::BEGIN@37 which was called:
# once (17.0ms+64.0ms) by installer::archivefiles::BEGIN@31 at line 37 # spent 81.0ms making 1 call to installer::exiter::BEGIN@37
# spent 9µs making 1 call to UNIVERSAL::import |
38 | |||||
39 | ############################################ | ||||
40 | # Exiting the program with an error | ||||
41 | # This function is used instead of "die" | ||||
42 | ############################################ | ||||
43 | |||||
44 | sub exit_program | ||||
45 | { | ||||
46 | my ($message, $function) = @_; | ||||
47 | |||||
48 | # If an installation set is currently created, the directory name is saved in $installer::globals::saveinstalldir | ||||
49 | # If this directory name matches with "_inprogress", it has to be renamed into "_witherror" | ||||
50 | |||||
51 | if ( $installer::globals::saveinstalldir =~ /_inprogress/ ) { installer::systemactions::rename_string_in_directory($installer::globals::saveinstalldir, "_inprogress", "_witherror"); } | ||||
52 | |||||
53 | installer::worker::clean_output_tree(); # removing directories created in the output tree | ||||
54 | |||||
55 | # If @installer::globals::logfileinfo is not empty, it can be used. | ||||
56 | # Otherwise the content of @installer::globals::globallogfileinfo has to be used. | ||||
57 | |||||
58 | my $infoline; | ||||
59 | |||||
60 | $installer::globals::logfilename = $installer::globals::exitlog . $installer::globals::logfilename; | ||||
61 | |||||
62 | if ( ! $installer::globals::globalinfo_copied ) { installer::logger::copy_globalinfo_into_logfile(); } | ||||
63 | |||||
64 | if ( $#installer::globals::logfileinfo > -1 ) | ||||
65 | { | ||||
66 | $infoline = "\n***************************************************************\n"; | ||||
67 | push(@installer::globals::logfileinfo, $infoline); | ||||
68 | |||||
69 | $infoline = "$message\n"; | ||||
70 | push(@installer::globals::logfileinfo, $infoline); | ||||
71 | |||||
72 | $infoline = "in function: $function\n"; | ||||
73 | push(@installer::globals::logfileinfo, $infoline); | ||||
74 | |||||
75 | $infoline = "***************************************************************\n"; | ||||
76 | push(@installer::globals::logfileinfo, $infoline); | ||||
77 | |||||
78 | installer::files::save_file($installer::globals::logfilename ,\@installer::globals::logfileinfo); | ||||
79 | } | ||||
80 | else | ||||
81 | { | ||||
82 | $infoline = "\n***************************************************************\n"; | ||||
83 | push(@installer::globals::globallogfileinfo, $infoline); | ||||
84 | |||||
85 | $infoline = "$message\n"; | ||||
86 | push(@installer::globals::globallogfileinfo, $infoline); | ||||
87 | |||||
88 | $infoline = "in function: $function\n"; | ||||
89 | push(@installer::globals::globallogfileinfo, $infoline); | ||||
90 | |||||
91 | $infoline = "***************************************************************\n"; | ||||
92 | push(@installer::globals::globallogfileinfo, $infoline); | ||||
93 | |||||
94 | installer::files::save_file($installer::globals::logfilename ,\@installer::globals::globallogfileinfo); | ||||
95 | } | ||||
96 | installer::logger::print_error("$message\nin function: $function"); | ||||
97 | print("ERROR, saved logfile $installer::globals::logfilename is:\n"); | ||||
98 | open(LOG, "<", $installer::globals::logfilename); | ||||
99 | print ": $_" while (<LOG>); | ||||
100 | print "\n"; | ||||
101 | close(LOG); | ||||
102 | |||||
103 | installer::logger::stoptime(); | ||||
104 | |||||
105 | exit(-1); | ||||
106 | } | ||||
107 | |||||
108 | 1 | 7µs | 1; |