OpenCoverage

savewd.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/coreutils/src/gnulib/lib/savewd.h
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6-
7-
8-
9-
10-
11-
12struct savewd-
13{-
14-
15 enum-
16 {-
17-
18-
19 INITIAL_STATE,-
20-
21-
22-
23 FD_STATE,-
24-
25-
26-
27 FD_POST_CHDIR_STATE,-
28-
29-
30-
31-
32 FORKING_STATE,-
33-
34-
35-
36 ERROR_STATE,-
37-
38-
39-
40-
41 FINAL_STATE-
42 } state;-
43-
44-
45 union-
46 {-
47 int fd;-
48 int errnum;-
49 pid_t child;-
50 } val;-
51};-
52-
53-
54inline void-
55savewd_init (struct savewd *wd)-
56{-
57 wd->state = INITIAL_STATE;-
58}
executed 259 times by 2 tests: end of block
Executed by:
  • ginstall
  • mkdir
259
59-
60-
61-
62enum-
63 {-
64-
65 SAVEWD_CHDIR_NOFOLLOW = 1,-
66-
67-
68-
69 SAVEWD_CHDIR_SKIP_READABLE = 2-
70 };-
71int savewd_chdir (struct savewd *wd, char const *dir, int options,-
72 int open_result[2]);-
73-
74-
75-
76-
77-
78-
79-
80int savewd_restore (struct savewd *wd, int status);-
81-
82-
83inline int __attribute__ ((__pure__))-
84savewd_errno (struct savewd const *wd)-
85{-
86 return
executed 10279 times by 2 tests: return (wd->state == ERROR_STATE ? wd->val.errnum : 0);
Executed by:
  • ginstall
  • mkdir
(wd->state == ERROR_STATE ? wd->val.errnum : 0);
executed 10279 times by 2 tests: return (wd->state == ERROR_STATE ? wd->val.errnum : 0);
Executed by:
  • ginstall
  • mkdir
10279
87}-
88-
89-
90-
91void savewd_finish (struct savewd *wd);-
92int savewd_process_files (int n_files, char **file,-
93 int (*act) (char *, struct savewd *, void *),-
94 void *options);-
95-
96-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.1.2