1
0
mirror of https://github.com/mpv-player/mpv synced 2025-01-21 23:23:19 +00:00

subprocess: minor cosmetic cleanup

Don't recursively include the whole stream.h header; only include what's
minimally needed, and handle the rest with forward declarations.
This commit is contained in:
wm4 2014-11-22 14:38:58 +01:00
parent 8097cee4c8
commit 1eeca36d5f
3 changed files with 9 additions and 5 deletions

View File

@ -15,8 +15,6 @@
* with mpv. If not, see <http://www.gnu.org/licenses/>.
*/
#include "osdep/subprocess.h"
#include <spawn.h>
#include <poll.h>
#include <unistd.h>
@ -25,8 +23,11 @@
#include <errno.h>
#include <signal.h>
#include "osdep/subprocess.h"
#include "osdep/io.h"
#include "common/common.h"
#include "stream/stream.h"
// Normally, this must be declared manually, but glibc is retarded.
#ifndef __GLIBC__

View File

@ -16,16 +16,17 @@
*/
#define _WIN32_WINNT 0x0600
#include "osdep/subprocess.h"
#include <windows.h>
#include <string.h>
#include "osdep/subprocess.h"
#include "osdep/io.h"
#include "osdep/atomics.h"
#include "talloc.h"
#include "common/common.h"
#include "stream/stream.h"
#include "misc/bstr.h"
static void write_arg(bstr *cmdline, char *arg)

View File

@ -18,7 +18,9 @@
#ifndef MP_SUBPROCESS_H_
#define MP_SUBPROCESS_H_
#include "stream/stream.h"
#include <stddef.h>
struct mp_cancel;
typedef void (*subprocess_read_cb)(void *ctx, char *data, size_t size);