1 --- cdrtools-3.00/./autoconf/configure.in~ 2010-05-07 20:00:25.000000000 +0300
2 +++ cdrtools-3.00/./autoconf/configure.in 2014-03-24 23:12:01.206179037 +0200
4 dnl POSIX rules. The new POSIX interfaces in question should be called
5 dnl fdexec*() to follow the rules of other similar POSIX functions.
7 -dnl We use AC_RCHECK_FUNCS() because some Linux distros define a
8 +dnl We use AC_CHECK_FUNCS() because some Linux distros define a
9 dnl fexecve() that returns ENOSYS an AC_CHECK_FUNCS() would return FALSE
11 echo Checking for POSIX violations by the POSIX.1-2008 standard:
12 -AC_RCHECK_FUNCS(fexecl fexecle fexecv fexecve)
13 -AC_RCHECK_FUNCS(fspawnv fspawnl fspawnv_nowait)
14 +AC_CHECK_FUNCS(fexecl fexecle fexecv fexecve)
15 +AC_CHECK_FUNCS(fspawnv fspawnl fspawnv_nowait)
17 dnl A similar problem exists with the new POSIX.1-2008 interfaces
18 dnl getline() and fgetline(). These interfaces are also incompatible
19 dnl with our interfaces defined in 1982.
20 -AC_RCHECK_FUNCS(getline fgetline)
21 +AC_CHECK_FUNCS(getline fgetline)
22 echo End of tests for POSIX violations by the POSIX.1-2008 standard.
24 dnl Check whether a symbol is either defined in an include file or
25 --- cdrtools-3.00/include/schily/schily.h~ 2009-10-23 00:18:55.000000000 +0300
26 +++ cdrtools-3.00/include/schily/schily.h 2014-03-24 23:14:00.498115198 +0200
28 #define fexecl js_fexecl
29 #define fexecle js_fexecle
30 #define fexecv js_fexecv
31 -#define fexecve js_fexecve
34 #define fspawnv js_fspawnv
36 #define fspawnl js_fspawnl
39 -#define getline js_getline
40 #define fgetline js_fgetline
44 /* 6th arg not const, fexecv forces av[ac] = NULL */
45 extern int fexecv __PR((const char *, FILE *, FILE *, FILE *, int,
47 -extern int fexecve __PR((const char *, FILE *, FILE *, FILE *,
48 +extern int js_fexecve __PR((const char *, FILE *, FILE *, FILE *,
49 char * const *, char * const *));
50 extern int fspawnv __PR((FILE *, FILE *, FILE *, int, char * const *));
51 extern int fspawnl __PR((FILE *, FILE *, FILE *, const char *, ...));
53 extern char *findinpath __PR((char *__name, int __mode, BOOL __plain_file));
54 extern int findline __PR((const char *, char, const char *,
56 -extern int getline __PR((char *, int));
57 +extern int js_getline __PR((char *, int));
58 extern int getstr __PR((char *, int));
59 extern int breakline __PR((char *, char, char **, int));
60 extern int getallargs __PR((int *, char * const**, const char *, ...));
61 --- cdrtools-3.00/libfind/find.c~ 2010-04-27 21:42:14.000000000 +0300
62 +++ cdrtools-3.00/libfind/find.c 2014-03-24 23:15:42.452619081 +0200
65 pp[ac] = NULL; /* -exec {} \; is not NULL terminated */
67 - fexecve(av[0], state->std[0], state->std[1], state->std[2],
68 + js_fexecve(av[0], state->std[0], state->std[1], state->std[2],
72 --- cdrtools-2.01.01/libscg/scsitransp.c.orig 2009-09-07 21:09:48.000000000 +0200
73 +++ cdrtools-2.01.01/libscg/scsitransp.c 2010-01-06 08:37:33.000000000 +0100
78 - if (getline(okbuf, sizeof (okbuf)) == EOF)
79 + if (js_getline(okbuf, sizeof (okbuf)) == EOF)
81 if (streql(okbuf, "y") || streql(okbuf, "yes") ||
82 streql(okbuf, "Y") || streql(okbuf, "YES"))
83 --- cdrtools-2.01.01/libschily/fexec.c.orig 2009-11-15 15:14:28.000000000 +0100
84 +++ cdrtools-2.01.01/libschily/fexec.c 2010-01-06 08:41:20.000000000 +0100
89 - ret = fexecv(name, in, out, err, ac, av);
90 + ret = js_fexecv(name, in, out, err, ac, av);
98 -fexecle(const char *name, FILE *in, FILE *out, FILE *err, const char *arg0, ...)
99 +js_fexecle(const char *name, FILE *in, FILE *out, FILE *err, const char *arg0, ...)
102 -fexecle(name, in, out, err, arg0, va_alist)
103 +js_fexecle(name, in, out, err, arg0, va_alist)
107 @@ -198,25 +198,25 @@
111 - ret = fexecve(name, in, out, err, av, env);
112 + ret = js_fexecve(name, in, out, err, av, env);
119 -fexecv(name, in, out, err, ac, av)
120 +js_fexecv(name, in, out, err, ac, av)
122 FILE *in, *out, *err;
126 av[ac] = NULL; /* force list to be null terminated */
127 - return (fexecve(name, in, out, err, av, environ));
128 + return (js_fexecve(name, in, out, err, av, environ));
132 -fexecve(name, in, out, err, av, env)
133 +js_fexecve(name, in, out, err, av, env)
135 FILE *in, *out, *err;
136 char * const av[], * const env[];
137 --- cdrtools-2.01.01/libschily/spawn.c.orig 2010-01-06 08:45:54.000000000 +0100
138 +++ cdrtools-2.01.01/libschily/spawn.c 2010-01-06 08:45:43.000000000 +0100
139 @@ -127,10 +127,10 @@
143 - * silly: fexecv must set av[ac] = NULL
144 + * silly: js_fexecv must set av[ac] = NULL
145 * so we have to cast argv tp (char **)
147 - fexecv(name, in, out, err, argc, (char **)argv);
148 + js_fexecv(name, in, out, err, argc, (char **)argv);
152 --- cdrtools-2.01.01/libschily/stdio/fgetline.c.orig 2004-09-25 14:23:36.000000000 +0200
153 +++ cdrtools-2.01.01/libschily/stdio/fgetline.c 2010-01-06 08:34:46.000000000 +0100
159 +js_getline(buf, len)
163 --- cdrtools-2.01.01/readcd/io.c.orig 2010-01-06 08:29:06.000000000 +0100
164 +++ cdrtools-2.01.01/readcd/io.c 2010-01-06 08:29:31.000000000 +0100
166 (*prt)(s, *lp, mini, maxi, dp);
169 - if (getline(line, 80) == EOF)
170 + if (js_getline(line, 80) == EOF)
173 linep = skipwhite(line);
175 printf("%r", form, args);
178 - if (getline(okbuf, sizeof (okbuf)) == EOF)
179 + if (js_getline(okbuf, sizeof (okbuf)) == EOF)
181 if (okbuf[0] == '?') {
182 printf("Enter 'y', 'Y', 'yes' or 'YES' if you agree with the previous asked question.\n");
183 --- cdrtools-2.01.01/readcd/readcd.c.orig 2010-01-06 08:27:59.000000000 +0100
184 +++ cdrtools-2.01.01/readcd/readcd.c 2010-01-06 08:28:36.000000000 +0100
185 @@ -2098,7 +2098,7 @@
186 error("Copy from SCSI (%d,%d,%d) disk to file\n",
187 scg_scsibus(scgp), scg_target(scgp), scg_lun(scgp));
188 error("Enter filename [%s]: ", defname); flush();
189 - (void) getline(filename, sizeof (filename));
190 + (void) js_getline(filename, sizeof (filename));
194 @@ -2285,7 +2285,7 @@
195 error("Copy from file to SCSI (%d,%d,%d) disk\n",
196 scg_scsibus(scgp), scg_target(scgp), scg_lun(scgp));
197 error("Enter filename [%s]: ", defname); flush();
198 - (void) getline(filename, sizeof (filename));
199 + (void) js_getline(filename, sizeof (filename));
200 error("Notice: reading from file always starts at file offset 0.\n");
202 getlong("Enter starting sector for copy:", &addr, 0L, end-1);
203 --- cdrtools-2.01.01/scgcheck/dmaresid.c.orig 2010-01-06 08:24:34.000000000 +0100
204 +++ cdrtools-2.01.01/scgcheck/dmaresid.c 2010-01-06 08:25:01.000000000 +0100
206 printf("Ready to start test for working DMA residual count == DMA count? Enter <CR> to continue: ");
207 fprintf(logfile, "**********> Testing for working DMA residual count == DMA count.\n");
209 - (void) getline(abuf, sizeof (abuf));
210 + (void) js_getline(abuf, sizeof (abuf));
213 ret = xtinquiry(scgp, 0, dmacnt);
216 printf("Ready to start test for working DMA residual count == 1? Enter <CR> to continue: ");
218 - (void) getline(abuf, sizeof (abuf));
219 + (void) js_getline(abuf, sizeof (abuf));
220 chkprint("**********> Testing for working DMA residual count == 1.\n");
225 printf("Ready to start test for working DMA overrun detection? Enter <CR> to continue: ");
227 - (void) getline(abuf, sizeof (abuf));
228 + (void) js_getline(abuf, sizeof (abuf));
229 chkprint("**********> Testing for working DMA overrun detection.\n");
232 --- cdrtools-2.01.01/scgcheck/scgcheck.c.orig 2010-01-06 08:26:33.000000000 +0100
233 +++ cdrtools-2.01.01/scgcheck/scgcheck.c 2010-01-06 08:27:29.000000000 +0100
236 error("Enter SCSI device name for bus scanning [%s]: ", device);
238 - (void) getline(device, sizeof (device));
239 + (void) js_getline(device, sizeof (device));
240 if (device[0] == '\0')
241 strcpy(device, "0,6,0");
247 - return (getline(lbuf, len));
248 + return (js_getline(lbuf, len));
250 --- cdrtools-3.00/scgcheck/sense.c~ 2010-05-24 12:19:15.000000000 +0300
251 +++ cdrtools-3.00/scgcheck/sense.c 2014-03-24 23:16:55.065826928 +0200
254 printf("Ready to eject tray? Enter <CR> to continue: ");
256 - (void) getline(abuf, sizeof (abuf));
257 + (void) js_getline(abuf, sizeof (abuf));
258 if (abuf[0] != 'n') {
259 scsi_unload(scgp, (cdr_t *)0);