Changeset 97cdbaf5 for zcrypt.c


Ignore:
Timestamp:
Mar 11, 2012, 10:57:35 PM (9 years ago)
Author:
David Benjamin <davidben@mit.edu>
Branches:
master, release-1.9
Children:
a03a409
Parents:
1f39ded
git-author:
David Benjamin <davidben@mit.edu> (01/23/12 00:38:29)
git-committer:
David Benjamin <davidben@mit.edu> (03/11/12 22:57:35)
Message:
Rewrite call_filter to use g_spawn_async_with_pipes

This simplifies the error-handling code. Also fixes a bug where file
descriptors get double-closed in call_filter. Also adds a unit test. The
separate prog argument is removed to avoid having to deal with
G_SPAWN_FILE_AND_ARGV_ZERO, and since we don't really use it anyway.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • zcrypt.c

    rc6332f5 r97cdbaf5  
    774774    NULL
    775775  };
    776   err = call_filter("gpg", argv, in, &out, &status);
     776  err = call_filter(argv, in, &out, &status);
    777777  if(err || status) {
    778778    g_free(out);
     
    857857  if(!in) return FALSE;
    858858
    859   err = call_filter("gpg", argv, in, &out, &status);
     859  err = call_filter(argv, in, &out, &status);
    860860  if(err || status) {
    861861    g_free(out);
Note: See TracChangeset for help on using the changeset viewer.