* rungpg.c (struct reap_s, reap_list, reap_list_lock): Moved to ...
* engine.c (struct reap_s, reap_list, reap_list_lock): ... here.
Include `time.h', `sys/types.h', `assert.h', and `sema.h'.
* rungpg.c (_gpgme_engine_add_child_to_reap_list): New function.
(do_reaping, _gpgme_gpg_housecleaning): Moved to ...
* engine.c (do_reaping, _gpgme_engine_housecleaning): ... here.
* rungpg.c (_gpgme_gpg_release): Replace code that is now in its
own function by call to _gpgme_engine_add_child_to_reap_list().
* wait.c: Include `engine.h'.
(run_idle): Call _gpgme_engine_housecleaning(), not
_gpgme_gpg_housecleaning().
* key.c (_gpgme_key_append_name): Append, not prepend, the uid.
Initialize the next field of the uid structure.
(gpgme_key_get_as_xml): Do not list last uid first.
* engine-gpgsm.c (_gpgme_gpgsm_op_verify): Put TEXT into
message_data, not SIG.
(_gpgme_gpgsm_op_sign): Use `--detached', not `--detach'.
* sign.c (sign_status_handler): Call
_gpgme_passphrase_status_handler early.
2001-12-14 Marcus Brinkmann <marcus@g10code.de>
* configure.ac (GPG): Substitute this variable.
(GPGSM): Likewise.
tests/
CVS2001-12-14 Marcus Brinkmann <marcus@g10code.de>
* gpg/Makefile.am (GPG): Set to @GPG_PATH@.
(./pubring.gpg): Use $(GPG) instead gpg.
(./secring.gpg): Likewise.
* gpgsm/t-import.c (main): Remove third test case.
* gpgsm/Makefile.am (GPGSM): Set to @GPGSM@.
(all-local): New target.
(./pubcerts.kbx): Likewise.
* gpgsm/t-encrypt.c: New file.
* gpgsm/Makefile.am (TESTS): Add t-encrypt.
* assuan-buffer.c (_assuan_read_line): New variable ATTICLEN, use
it to save the number of bytes left over after the complete line.
Rediddle the code a bit to make it more clear what happens.
2001-12-14 Marcus Brinkmann <marcus@g10code.de>
* engine-gpgsm.c (struct gpgsm_object_s): New member colon.attic.
(_gpgme_gpgsm_new): Initialize some more members.
(_gpgme_gpgsm_release): Free the colon line handler's attic line.
(gpgsm_status_handler): Rework the inline-data processing.
tests/
2001-12-14 Marcus Brinkmann <marcus@g10code.de>
* gpgsm/t-keylist.c: New file.
* gpgsm/Makefile.am (TESTS): Add t-keylist.
* rungpg.c (_gpgme_gpg_spawn): Do not add the fds to the child
list that are not dup'ed, for those the close-on-exec flag is set
now.
* version.c (_gpgme_get_program_version): Remove first entry in
CFD, as the close-on-exec flag is now set for this fd.
* engine-gpgsm.c (_gpgme_gpgsm_op_encrypt): Do not add `armor'
option to `ENCRYPT'.
* engine-gpgsm.c (gpgsm_set_recipients): Free LINE when returning
successfully.
* engine-gpgsm.c (close_notify_handler): New function.
(_gpgme_gpgsm_new): Manage the file descriptors a
bit differently. Do not set close-on-exec flags.
(_gpgme_gpgsm_op_decrypt): Do not set message_fd
to -1, this is done by the close handler.
(_gpgme_gpgsm_op_encrypt): Likewise.
(_gpgme_gpgsm_op_import): Likewise (also for output_fd).
(_gpgme_gpgsm_op_keylist): Likewise (also for input_fd and output_fd).
(_gpgme_gpgsm_op_sign): Likewise.
(_gpgme_gpgsm_op_verify): Likewise, but for output_fd.
* posix-io.c (_gpgme_io_pipe): Set the close-on-exec flag for the
non-inherited file descriptor index of the pipe.
(gpgsm_status_handler): Pass datalines to a colon handler
* engine.c (_gpgme_engine_set_colon_line_handler): Set the colon
handler for gpgsm.
* engine-gpgsm.c (_gpgme_gpgsm_op_keylist): Allow NULL for
pattern.
(gpgsm_assuan_simple_command): Removed underscore from
assuan_write_line.
(_gpgme_gpgsm_start): Ditto.
(gpgsm_assuan_simple_command): Replaced interal Assuan read
function by the new assuan_read_line. Removed the use of the
internal header.
(gpgsm_status_handler): Ditto. Use the new assuan_pending_line.
(_gpgme_gpgsm_start): Use the documented way to get an fd from
assuan.
pattern.
(gpgsm_assuan_simple_command): Removed underscore from
assuan_write_line.
(_gpgme_gpgsm_start): Ditto.
* keylist.c (keylist_colon_handler): Handle "crt" records
* key.h (gpgme_key_s): Add an x509 flag.
* key.c (parse_x509_user_id): New.
(_gpgme_key_append_name): Handle x.509 names.
However, it does not yet work.