OpenCoverage

version.c

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/bash/src/version.c
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7extern char *shell_name;-
8-
9-
10const char * const dist_version = "5.0";-
11const int patch_level = 0;-
12const int build_version = 1;-
13-
14const char * const release_status = "alpha";-
15-
16-
17-
18const char * const sccs_version = "@(#)Bash version 5.0.0(1) alpha GNU";-
19-
20const char * const bash_copyright = "Copyright (C) 2016 Free Software Foundation, Inc.";-
21const char * const bash_license = "License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>\n";-
22-
23-
24int shell_compatibility_level = 50;-
25-
26-
27-
28-
29extern char *shell_version_string (void);-
30extern void show_shell_version (int);-
31-
32-
33char *-
34shell_version_string ()-
35{-
36 static char tt[32] = { '\0' };-
37-
38 if (tt[0] == '\0'
tt[0] == '\0'Description
TRUEevaluated 5432 times by 1 test
Evaluated by:
  • Self test
FALSEevaluated 16 times by 1 test
Evaluated by:
  • Self test
)
16-5432
39 {-
40 if (release_status
release_statusDescription
TRUEevaluated 5432 times by 1 test
Evaluated by:
  • Self test
FALSEnever evaluated
)
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:
  • Self test
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: return tt;
Executed by:
  • Self test
tt;
executed 5448 times by 1 test: return tt;
Executed by:
  • Self test
5448
54}-
55-
56void-
57show_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
extendedDescription
TRUEnever evaluated
FALSEevaluated 1 time by 1 test
Evaluated by:
  • Self test
)
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:
  • Self test
1
Switch to Source codePreprocessed file

Generated by Squish Coco 4.1.2