1. 19 Dec, 2018 1 commit
    • Philip Withnall's avatar
      Revert "tests: Fix GOptionContext leak in GSubprocess tests" · ccb34865
      Philip Withnall authored
      This reverts commit 52bab025.
      It silently conflicted with another commit,
      90ca3b4d, which was merged later than
      it. I’ve kept commit 90ca3b because it also frees the GError; 52bab
      This is my failure to rebase and test old branches before merging them,
      instead of assuming that the lack of automatically detected merge
      conflicts actually means there are no merge conflicts.
  2. 01 Nov, 2018 1 commit
  3. 10 Oct, 2018 1 commit
  4. 03 Aug, 2017 1 commit
    • Philip Withnall's avatar
      Consistently save errno immediately after the operation setting it · 5cddde1f
      Philip Withnall authored
      Prevent the situation where errno is set by function A, then function B
      is called (which is typically _(), but could be anything else) and it
      overwrites errno, then errno is checked by the caller.
      errno is a horrific API, and we need to be careful to save its value as
      soon as a function call (which might set it) returns. i.e. Follow the
        int errsv, ret;
        ret = some_call_which_might_set_errno ();
        errsv = errno;
        if (ret < 0)
          puts (strerror (errsv));
      This patch implements that pattern throughout GLib. There might be a few
      places in the test code which still use errno directly. They should be
      ported as necessary. It doesn’t modify all the call sites like this:
        if (some_call_which_might_set_errno () && errno == ESOMETHING)
      since the refactoring involved is probably more harmful than beneficial
      there. It does, however, refactor other call sites regardless of whether
      they were originally buggy.
  5. 21 Jun, 2017 1 commit
  6. 02 Aug, 2014 1 commit
  7. 04 Mar, 2014 1 commit
  8. 28 Nov, 2013 2 commits
  9. 04 Nov, 2013 1 commit
  10. 21 Oct, 2013 1 commit
    • Allison Karlitskaya's avatar
      GSubprocess win32 fixups · 358588ed
      Allison Karlitskaya authored
      Note: we go out of our way not to pass a child setup function on win32
      (even if it does nothing) because we get a g_warning() from gspawn if we
      do so.
  11. 17 Oct, 2013 1 commit
    • Colin Walters's avatar
      GSubprocess: New class for spawning child processes · 5b48dc40
      Colin Walters authored
      There are a number of nice things this class brings:
      0) Has a race-free termination API on all platforms (on UNIX, calls to
         kill() and waitpid() are coordinated as not to cause problems).
      1) Operates in terms of G{Input,Output}Stream, not file descriptors
      2) Standard GIO-style async API for wait() with cancellation
      3) Makes some simple cases easy, like synchronously spawning a
         process with an argument list
      4) Makes hard cases possible, like asynchronously running a process
         with stdout/stderr merged, output directly to a file path
      Much rewriting and code review from Ryan Lortie <desrt@desrt.ca>