1 diff -urN cups-filters.orig/filter/imagetopdf.c cups-filters/filter/imagetopdf.c
2 --- cups-filters.orig/filter/imagetopdf.c 2013-02-05 14:49:33.165014130 +0900
3 +++ cups-filters/filter/imagetopdf.c 2013-02-05 14:51:33.465014116 +0900
5 #include <cupsfilters/image.h>
10 #if CUPS_VERSION_MAJOR < 1 \
11 || (CUPS_VERSION_MAJOR == 1 && CUPS_VERSION_MINOR < 2)
16 +#if defined(HAVE_SIGACTION) && !defined(HAVE_SIGSET)
17 + struct sigaction action; /* Actions for POSIX signals */
18 +#endif /* HAVE_SIGACTION && !HAVE_SIGSET */
20 + sigset(SIGPIPE, SIG_IGN);
21 +#elif defined(HAVE_SIGACTION)
22 + memset(&action, 0, sizeof(action));
23 + action.sa_handler = SIG_IGN;
24 + sigaction(SIGPIPE, &action, NULL);
26 + signal(SIGPIPE, SIG_IGN);
27 +#endif /* HAVE_SIGSET */
30 * Check command-line...
32 diff -urN cups-filters.orig/filter/pdftoijs.cxx cups-filters/filter/pdftoijs.cxx
33 --- cups-filters.orig/filter/pdftoijs.cxx 2013-02-05 14:49:33.161014130 +0900
34 +++ cups-filters/filter/pdftoijs.cxx 2013-02-05 14:52:58.129014106 +0900
40 #ifdef HAVE_CPP_POPPLER_VERSION_H
41 #include "cpp/poppler-version.h"
44 globalParams = new GlobalParams();
45 parseOpts(argc, argv);
47 +#if defined(HAVE_SIGACTION) && !defined(HAVE_SIGSET)
48 + struct sigaction action; /* Actions for POSIX signals */
49 +#endif /* HAVE_SIGACTION && !HAVE_SIGSET */
51 + sigset(SIGPIPE, SIG_IGN);
52 +#elif defined(HAVE_SIGACTION)
53 + memset(&action, 0, sizeof(action));
54 + action.sa_handler = SIG_IGN;
55 + sigaction(SIGPIPE, &action, NULL);
57 + signal(SIGPIPE, SIG_IGN);
58 +#endif /* HAVE_SIGSET */
63 diff -urN cups-filters.orig/filter/texttopdf.c cups-filters/filter/texttopdf.c
64 --- cups-filters.orig/filter/texttopdf.c 2013-02-05 14:49:33.165014130 +0900
65 +++ cups-filters/filter/texttopdf.c 2013-02-05 14:53:47.893014100 +0900
68 #include "fontembed/sfnt.h"
69 #include <fontconfig/fontconfig.h>
75 main(int argc, /* I - Number of command-line arguments */
76 char *argv[]) /* I - Command-line arguments */
78 +#if defined(HAVE_SIGACTION) && !defined(HAVE_SIGSET)
79 + struct sigaction action; /* Actions for POSIX signals */
80 +#endif /* HAVE_SIGACTION && !HAVE_SIGSET */
82 + sigset(SIGPIPE, SIG_IGN);
83 +#elif defined(HAVE_SIGACTION)
84 + memset(&action, 0, sizeof(action));
85 + action.sa_handler = SIG_IGN;
86 + sigaction(SIGPIPE, &action, NULL);
88 + signal(SIGPIPE, SIG_IGN);
89 +#endif /* HAVE_SIGSET */
90 return (TextMain("texttopdf", argc, argv));