Revert "Try fix of compile warnings about assigned but unused variables"
[midnight-commander.git] / src / background.h
blob1869528eddc5445fec3269f963a0b2131f94f25f
1 /** \file background.h
2 * \brief Header: Background support
3 */
5 #ifndef MC__BACKGROUND_H
6 #define MC__BACKGROUND_H
8 #include <sys/types.h> /* pid_t */
10 /*** typedefs(not structures) and defined constants **********************************************/
12 enum TaskState
14 Task_Running,
15 Task_Stopped
18 typedef struct TaskList
20 int fd;
21 int to_child_fd;
22 pid_t pid;
23 int state;
24 char *info;
25 struct TaskList *next;
26 } TaskList;
28 struct FileOpContext;
30 /*** enums ***************************************************************************************/
32 /*** structures declarations (and typedefs of structures)*****************************************/
34 /*** global variables defined in .c file *********************************************************/
36 extern struct TaskList *task_list;
38 /*** declarations of public functions ************************************************************/
40 int do_background (struct FileOpContext *ctx, char *info);
41 int parent_call (void *routine, struct FileOpContext *ctx, int argc, ...);
42 char *parent_call_string (void *routine, int argc, ...);
44 void unregister_task_running (pid_t pid, int fd);
45 void unregister_task_with_pid (pid_t pid);
47 gboolean background_parent_call (const gchar * event_group_name, const gchar * event_name,
48 gpointer init_data, gpointer data);
50 gboolean
51 background_parent_call_string (const gchar * event_group_name, const gchar * event_name,
52 gpointer init_data, gpointer data);
54 /*** inline functions ****************************************************************************/
56 #endif /* MC__BACKGROUND_H */