Line | |
---|
1 | /* sync - sync the disks by forcing pending filesystem writes to complete */
|
---|
2 |
|
---|
3 | #include <config.h>
|
---|
4 |
|
---|
5 | #ifdef HAVE_UNISTD_H
|
---|
6 | #include <unistd.h>
|
---|
7 | #endif
|
---|
8 |
|
---|
9 | #include "builtins.h"
|
---|
10 | #include "shell.h"
|
---|
11 | #include "bashgetopt.h"
|
---|
12 |
|
---|
13 | sync_builtin (list)
|
---|
14 | WORD_LIST *list;
|
---|
15 | {
|
---|
16 | sync();
|
---|
17 | return (EXECUTION_SUCCESS);
|
---|
18 | }
|
---|
19 |
|
---|
20 | char *sync_doc[] = {
|
---|
21 | "force completion of pending disk writes",
|
---|
22 | (char *)NULL
|
---|
23 | };
|
---|
24 |
|
---|
25 | struct builtin sync_struct = {
|
---|
26 | "sync", /* builtin name */
|
---|
27 | sync_builtin, /* function implementing the builtin */
|
---|
28 | BUILTIN_ENABLED, /* initial flags for builtin */
|
---|
29 | sync_doc, /* array of long documentation strings. */
|
---|
30 | "sync", /* usage synopsis; becomes short_doc */
|
---|
31 | 0 /* reserved for internal use */
|
---|
32 | };
|
---|
Note:
See
TracBrowser
for help on using the repository browser.