core,emacs,tty,curses: Fix memory leaks, invalid accese, and mistake.
* pinentry/pinentry-curses.c (dialog_create): Free NEW. [HAVE_NCURSESW] (dialog_run): Free OLD_CTYPE on error. * pinentry/pinentry.c (pinentry_inq_genpin): Free VALUE on error. * tty/pinentry-tty.c (tty_cmd_handler): Don't access closed FDs. * pinentry/pinentry-emacs.c (set_labels): Fix for ->default_cancel.
- GnuPG-bug-id: T5384
- Signed-off-by: Jakub Jelen <jjelen@redhat.com>