Absolute File Name: | /home/opencoverage/opencoverage/guest-scripts/bash/src/version.c |
Switch to Source code | Preprocessed file |
Line | Source | Count | ||||||
---|---|---|---|---|---|---|---|---|
1 | - | |||||||
2 | - | |||||||
3 | - | |||||||
4 | - | |||||||
5 | - | |||||||
6 | - | |||||||
7 | extern char *shell_name; | - | ||||||
8 | - | |||||||
9 | - | |||||||
10 | const char * const dist_version = "5.0"; | - | ||||||
11 | const int patch_level = 0; | - | ||||||
12 | const int build_version = 1; | - | ||||||
13 | - | |||||||
14 | const char * const release_status = "alpha"; | - | ||||||
15 | - | |||||||
16 | - | |||||||
17 | - | |||||||
18 | const char * const sccs_version = "@(#)Bash version 5.0.0(1) alpha GNU"; | - | ||||||
19 | - | |||||||
20 | const char * const bash_copyright = "Copyright (C) 2016 Free Software Foundation, Inc."; | - | ||||||
21 | const char * const bash_license = "License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n"; | - | ||||||
22 | - | |||||||
23 | - | |||||||
24 | int shell_compatibility_level = 50; | - | ||||||
25 | - | |||||||
26 | - | |||||||
27 | - | |||||||
28 | - | |||||||
29 | extern char *shell_version_string (void); | - | ||||||
30 | extern void show_shell_version (int); | - | ||||||
31 | - | |||||||
32 | - | |||||||
33 | char * | - | ||||||
34 | shell_version_string () | - | ||||||
35 | { | - | ||||||
36 | static char tt[32] = { '\0' }; | - | ||||||
37 | - | |||||||
38 | if (tt[0] == '\0'
| 16-5432 | ||||||
39 | { | - | ||||||
40 | if (release_status
| 0-5432 | ||||||
41 | - | |||||||
42 | snprintf (tt, sizeof (tt), "%s.%d(%d)-%s", dist_version, patch_level, build_version, release_status); executed 5432 times by 1 test: snprintf (tt, sizeof (tt), "%s.%d(%d)-%s", dist_version, patch_level, build_version, release_status); Executed by:
| 5432 | ||||||
43 | - | |||||||
44 | - | |||||||
45 | - | |||||||
46 | else | - | ||||||
47 | - | |||||||
48 | snprintf (tt, sizeof (tt), "%s.%d(%d)", dist_version, patch_level, build_version); never executed: snprintf (tt, sizeof (tt), "%s.%d(%d)", dist_version, patch_level, build_version); | 0 | ||||||
49 | - | |||||||
50 | - | |||||||
51 | - | |||||||
52 | } | - | ||||||
53 | return executed 5448 times by 1 test: tt;return tt; Executed by:
executed 5448 times by 1 test: return tt; Executed by:
| 5448 | ||||||
54 | } | - | ||||||
55 | - | |||||||
56 | void | - | ||||||
57 | show_shell_version (extended) | - | ||||||
58 | int extended; | - | ||||||
59 | { | - | ||||||
60 | printf ( | - | ||||||
61 | dcgettext (((void *)0), | - | ||||||
62 | "GNU bash, version %s (%s)\n" | - | ||||||
63 | , 5) | - | ||||||
64 | , shell_version_string (), "x86_64-pc-linux-gnu"); | - | ||||||
65 | if (extended
| 0-1 | ||||||
66 | { | - | ||||||
67 | printf ("%s\n", | - | ||||||
68 | dcgettext (((void *)0), | - | ||||||
69 | bash_copyright | - | ||||||
70 | , 5) | - | ||||||
71 | ); | - | ||||||
72 | printf ("%s\n", | - | ||||||
73 | dcgettext (((void *)0), | - | ||||||
74 | bash_license | - | ||||||
75 | , 5) | - | ||||||
76 | ); | - | ||||||
77 | printf ("%s\n", | - | ||||||
78 | dcgettext (((void *)0), | - | ||||||
79 | "This is free software; you are free to change and redistribute it." | - | ||||||
80 | , 5) | - | ||||||
81 | ); | - | ||||||
82 | printf ("%s\n", | - | ||||||
83 | dcgettext (((void *)0), | - | ||||||
84 | "There is NO WARRANTY, to the extent permitted by law." | - | ||||||
85 | , 5) | - | ||||||
86 | ); | - | ||||||
87 | } never executed: end of block | 0 | ||||||
88 | } executed 1 time by 1 test: end of block Executed by:
| 1 | ||||||
Switch to Source code | Preprocessed file |