Changeset 252 for trunk/src/sh_gpg.c
- Timestamp:
- Oct 12, 2009, 10:40:45 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/sh_gpg.c
r248 r252 88 88 FILE * pdbgc; 89 89 #define PDBG_OPEN pdbg = fopen(PDGBFILE"main", "a") 90 #define PDBG_CLOSE fclose (pdbg)90 #define PDBG_CLOSE sl_fclose (FIL__, __LINE__, pdbg) 91 91 #define PDBG(arg) fprintf(pdbg, "PDBG: step %d\n", arg); fflush(pdbg) 92 92 #define PDBG_D(arg) fprintf(pdbg, "PDBG: %d\n", arg); fflush(pdbg) … … 94 94 95 95 #define PDBGC_OPEN pdbgc = fopen(PDGBFILE"child", "a") 96 #define PDBGC_CLOSE fclose (pdbgc)96 #define PDBGC_CLOSE sl_fclose (FIL__, __LINE__, pdbgc) 97 97 #define PDBGC(arg) fprintf(pdbgc, "PDBG: step %d\n", arg); fflush(pdbgc) 98 98 #define PDBGC_D(arg) fprintf(pdbgc, "PDBG: %d\n", arg); fflush(pdbgc) … … 446 446 if (source->pid == (pid_t) - 1) 447 447 { 448 close(pipedes[0]);449 close(pipedes[1]);448 sl_close_fd(FIL__, __LINE__, pipedes[0]); 449 sl_close_fd(FIL__, __LINE__, pipedes[1]); 450 450 if (envp[0] != NULL) 451 451 free(envp[0]); … … 468 468 /* close the pipe descriptors 469 469 */ 470 close (pipedes[STDIN_FILENO]);471 close (pipedes[STDOUT_FILENO]);470 sl_close_fd (FIL__, __LINE__, pipedes[STDIN_FILENO]); 471 sl_close_fd (FIL__, __LINE__, pipedes[STDOUT_FILENO]); 472 472 473 473 … … 618 618 free(envp[0]); 619 619 620 close (pipedes[STDOUT_FILENO]);620 sl_close_fd (FIL__, __LINE__, pipedes[STDOUT_FILENO]); 621 621 retry_fcntl (FIL__, __LINE__, pipedes[STDIN_FILENO], F_SETFD, FD_CLOEXEC); 622 622 retry_fcntl (FIL__, __LINE__, pipedes[STDIN_FILENO], F_SETFL, O_NONBLOCK); … … 627 627 { 628 628 aud_kill (FIL__, __LINE__, source->pid, SIGKILL); 629 close (pipedes[STDOUT_FILENO]);629 sl_close_fd (FIL__, __LINE__, pipedes[STDOUT_FILENO]); 630 630 waitpid (source->pid, NULL, 0); 631 631 source->pid = 0; … … 643 643 SL_ENTER(_("sh_gpg_pclose")); 644 644 645 status = fclose(source->pipe);645 status = sl_fclose(FIL__, __LINE__, source->pipe); 646 646 if (status) 647 647 SL_RETURN( (-1), _("sh_gpg_pclose"));
Note:
See TracChangeset
for help on using the changeset viewer.