]> git.pld-linux.org Git - packages/dialog.git/blame - dialog-segv.patch
perl -pi -e "s/^automake -a -c -f --foreing/\%\{__automake\}/; \
[packages/dialog.git] / dialog-segv.patch
CommitLineData
7818e2e9
MM
1--- dialog-0.69.orig/dialog.c Tue Jan 16 13:03:40 1996
2+++ dialog-0.69/dialog.c Mon May 20 23:02:03 2002
c5dcf0e2
MM
3@@ -150,7 +150,7 @@
4 break; /* not found */
00912089 5 }
c5dcf0e2
MM
6
7- if (argc<3) {
8+ if (argc<3 || !optPtr) {
00912089 9 Usage (prgname);
c5dcf0e2 10 exit(DIALOG_ERROR);
00912089 11 }
7818e2e9
MM
12--- dialog-0.69.orig/text.c Tue Jan 16 11:34:35 1996
13+++ dialog-0.69/text.c Mon May 20 23:03:23 2002
14@@ -35,10 +35,10 @@
15 static char *buf, *page;
16
17 /* Silly function, to remove duplicates */
18-static int fatal(char *msg, int errno)
19+static int fatal(char *msg, int error)
20 {
21 endwin();
22- fprintf(stderr,"dialog_textbox(): %s: %s\n",msg,strerror(errno));
23+ fprintf(stderr,"dialog_textbox(): %s: %s\n",msg,strerror(error));
24 exit(DIALOG_ERROR);
25 }
26
27--- dialog-0.69.orig/util.c Tue Jan 16 11:34:35 1996
28+++ dialog-0.69/util.c Mon May 20 23:02:03 2002
c5dcf0e2
MM
29@@ -239,8 +239,8 @@
30 /*
31 * Ok, now fix width and height. Default to a margin of 3 on each side.
32 */
33- if (desc->c_wid==0) desc->c_wid=-3;
34- if (desc->c_hei==0) desc->c_hei=-3;
35+ if (desc->c_wid <= 0 || desc->c_wid > ws.ws_col) desc->c_wid=-3;
36+ if (desc->c_hei <= 0 || desc->c_hei > ws.ws_row) desc->c_hei=-3;
37
38 desc->wid=desc->c_wid; desc->hei=desc->c_hei;
39
This page took 0.630739 seconds and 4 git commands to generate.