cleanup for gcc 4
This commit is contained in:
parent
0ad1957d15
commit
23ad3c22f7
@ -1,4 +1,4 @@
|
||||
/* $OpenBSD: cdrom_freebsd.c,v 1.2 2003/08/24 22:15:56 naddy Exp $ */
|
||||
/* $OpenBSD: cdrom_freebsd.c,v 1.3 2010/05/17 08:31:11 espie Exp $ */
|
||||
/*
|
||||
* Copyright (C) 1990 Regents of the University of California.
|
||||
*
|
||||
@ -17,6 +17,7 @@
|
||||
static int c;
|
||||
|
||||
# include <stdio.h>
|
||||
# include <stdlib.h>
|
||||
# include <sys/file.h>
|
||||
# include <sys/types.h>
|
||||
# include <sys/param.h>
|
||||
@ -555,7 +556,6 @@ unsigned short *
|
||||
ushort_malloc(n)
|
||||
int n;
|
||||
{
|
||||
extern char *calloc();
|
||||
unsigned short *ptr;
|
||||
|
||||
ptr = (unsigned short *) calloc(n, sizeof(unsigned short));
|
||||
@ -571,7 +571,6 @@ struct msf *
|
||||
msf_malloc(n)
|
||||
int n;
|
||||
{
|
||||
extern char *calloc();
|
||||
struct msf *ptr;
|
||||
|
||||
ptr = (struct msf *) calloc(n, sizeof(struct msf));
|
||||
|
@ -1,7 +1,11 @@
|
||||
$OpenBSD: patch-cdrom_callb_c,v 1.2 2008/01/30 15:02:51 jasper Exp $
|
||||
$OpenBSD: patch-cdrom_callb_c,v 1.3 2010/05/17 08:31:12 espie Exp $
|
||||
--- cdrom_callb.c.orig Tue Jan 12 19:59:48 1993
|
||||
+++ cdrom_callb.c Wed Jan 30 16:01:35 2008
|
||||
@@ -22,6 +22,9 @@
|
||||
+++ cdrom_callb.c Mon May 17 10:28:00 2010
|
||||
@@ -19,9 +19,13 @@
|
||||
# include <X11/Xaw/Toggle.h>
|
||||
|
||||
# include <stdio.h>
|
||||
+# include <stdlib.h>
|
||||
|
||||
# include "debug.h"
|
||||
# include "cdrom_globs.h"
|
||||
@ -11,7 +15,7 @@ $OpenBSD: patch-cdrom_callb_c,v 1.2 2008/01/30 15:02:51 jasper Exp $
|
||||
#ifdef sun
|
||||
# include "cdrom_sun.h"
|
||||
#endif
|
||||
@@ -29,6 +32,8 @@
|
||||
@@ -29,6 +33,8 @@
|
||||
# include "cdrom_sgi.h"
|
||||
#endif
|
||||
|
||||
@ -20,7 +24,7 @@ $OpenBSD: patch-cdrom_callb_c,v 1.2 2008/01/30 15:02:51 jasper Exp $
|
||||
void cdrom_new_disc();
|
||||
|
||||
/*
|
||||
@@ -287,7 +292,7 @@ cb_cdrom_previous(widget, client_data, call_data)
|
||||
@@ -287,7 +293,7 @@ cb_cdrom_previous(widget, client_data, call_data)
|
||||
* if playing less than replayThreshold seconds, back up to
|
||||
* previous track; otherwise start at beginning of current track:
|
||||
*/
|
||||
|
@ -1,6 +1,6 @@
|
||||
$OpenBSD: patch-internals_c,v 1.1 2003/08/24 22:15:56 naddy Exp $
|
||||
--- internals.c.orig 1993-01-12 19:59:45.000000000 +0100
|
||||
+++ internals.c 2003-08-24 23:13:27.000000000 +0200
|
||||
$OpenBSD: patch-internals_c,v 1.2 2010/05/17 08:31:12 espie Exp $
|
||||
--- internals.c.orig Tue Jan 12 19:59:45 1993
|
||||
+++ internals.c Mon May 17 10:24:16 2010
|
||||
@@ -22,6 +22,9 @@
|
||||
|
||||
# include "debug.h"
|
||||
@ -27,6 +27,21 @@ $OpenBSD: patch-internals_c,v 1.1 2003/08/24 22:15:56 naddy Exp $
|
||||
|
||||
int
|
||||
cdrom_get_curtime() {
|
||||
@@ -77,13 +81,13 @@ cdrom_get_curtime() {
|
||||
}
|
||||
|
||||
|
||||
+static void update_track();
|
||||
/*
|
||||
* we poll the cd-rom drive every TIMER_PERIOD milliseconds to see where
|
||||
* it is and if it's on a new track, and update the label widget.
|
||||
*/
|
||||
void
|
||||
cdrom_timer_on() {
|
||||
- static void update_track();
|
||||
|
||||
if (cdi.state & CDROM_STATE_PLAY)
|
||||
ivid = XtAppAddTimeOut(appc, TIMER_PERIOD, update_track, NULL);
|
||||
@@ -170,7 +174,6 @@ cdrom_rewind () {
|
||||
struct msf track_start;
|
||||
struct msf start_addr, end_addr;
|
||||
|
@ -1,18 +1,33 @@
|
||||
$OpenBSD: patch-main_c,v 1.1 2003/08/24 22:15:56 naddy Exp $
|
||||
--- main.c.orig 1993-01-12 19:59:36.000000000 +0100
|
||||
+++ main.c 2003-08-24 23:21:50.000000000 +0200
|
||||
@@ -23,7 +23,9 @@
|
||||
$OpenBSD: patch-main_c,v 1.2 2010/05/17 08:31:12 espie Exp $
|
||||
--- main.c.orig Tue Jan 12 19:59:36 1993
|
||||
+++ main.c Mon May 17 10:22:50 2010
|
||||
@@ -14,6 +14,7 @@
|
||||
*/
|
||||
|
||||
# include <stdio.h>
|
||||
+# include <stdlib.h>
|
||||
|
||||
# include <X11/Intrinsic.h>
|
||||
# include <X11/StringDefs.h>
|
||||
@@ -23,12 +24,15 @@
|
||||
|
||||
Widget top_form;
|
||||
|
||||
-void
|
||||
+extern AppData app_data;
|
||||
+
|
||||
+static void chk_debug(int, char **);
|
||||
+
|
||||
+int
|
||||
main(argc, argv)
|
||||
int argc;
|
||||
char **argv;
|
||||
@@ -66,7 +68,7 @@ chk_debug(argc, argv)
|
||||
{
|
||||
- static void chk_debug();
|
||||
|
||||
chk_debug(argc, argv);
|
||||
|
||||
@@ -66,7 +70,7 @@ chk_debug(argc, argv)
|
||||
/* ugly hack */
|
||||
for (i = 1; i < argc; i++) {
|
||||
if (strcmp(argv[i], "-debug") == 0) {
|
||||
|
@ -1,7 +1,11 @@
|
||||
$OpenBSD: patch-shuffle_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
--- shuffle.c.orig Tue Jan 12 11:59:38 1993
|
||||
+++ shuffle.c Sat Nov 19 08:30:06 2005
|
||||
@@ -18,6 +18,9 @@
|
||||
$OpenBSD: patch-shuffle_c,v 1.3 2010/05/17 08:31:12 espie Exp $
|
||||
--- shuffle.c.orig Tue Jan 12 19:59:38 1993
|
||||
+++ shuffle.c Mon May 17 10:25:14 2010
|
||||
@@ -15,9 +15,13 @@
|
||||
|
||||
# include <X11/Intrinsic.h>
|
||||
# include <stdio.h>
|
||||
+# include <stdlib.h>
|
||||
|
||||
# include "debug.h"
|
||||
# include "cdrom_globs.h"
|
||||
@ -11,7 +15,7 @@ $OpenBSD: patch-shuffle_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
#ifdef sun
|
||||
# include "cdrom_sun.h"
|
||||
#endif
|
||||
@@ -29,10 +32,12 @@
|
||||
@@ -29,10 +33,11 @@
|
||||
|
||||
static unsigned char *random_tracks;
|
||||
|
||||
@ -19,7 +23,7 @@ $OpenBSD: patch-shuffle_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
+
|
||||
void
|
||||
shuffle_setup() {
|
||||
extern char *malloc();
|
||||
- extern char *malloc();
|
||||
-#ifdef sgi
|
||||
+#if defined sgi || defined __OpenBSD__
|
||||
extern time_t time(time_t *);
|
||||
|
@ -1,7 +1,15 @@
|
||||
$OpenBSD: patch-top_setup_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
--- top_setup.c.orig Tue Jan 12 11:59:40 1993
|
||||
+++ top_setup.c Wed Nov 16 21:18:21 2005
|
||||
@@ -26,19 +26,9 @@
|
||||
$OpenBSD: patch-top_setup_c,v 1.3 2010/05/17 08:31:12 espie Exp $
|
||||
--- top_setup.c.orig Tue Jan 12 19:59:40 1993
|
||||
+++ top_setup.c Mon May 17 10:27:08 2010
|
||||
@@ -19,6 +19,7 @@
|
||||
# include <X11/Xaw/Form.h>
|
||||
|
||||
# include <stdio.h>
|
||||
+# include <stdlib.h>
|
||||
# include <string.h>
|
||||
|
||||
# include "cdrom_globs.h"
|
||||
@@ -26,19 +27,9 @@
|
||||
# include "logo.xbm"
|
||||
|
||||
XtAppContext appc;
|
||||
@ -23,7 +31,7 @@ $OpenBSD: patch-top_setup_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
extern char *getenv();
|
||||
|
||||
static Widget top_shell;
|
||||
@@ -55,36 +45,36 @@ static XrmOptionDescRec options[] = {
|
||||
@@ -55,36 +46,36 @@ static XrmOptionDescRec options[] = {
|
||||
};
|
||||
|
||||
static XtResource resources[] = {
|
||||
@ -79,7 +87,7 @@ $OpenBSD: patch-top_setup_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
};
|
||||
|
||||
Widget
|
||||
@@ -98,6 +88,20 @@ top_setup(argc, argv)
|
||||
@@ -98,6 +89,20 @@ top_setup(argc, argv)
|
||||
Arg arg;
|
||||
char *s;
|
||||
|
||||
@ -100,7 +108,7 @@ $OpenBSD: patch-top_setup_c,v 1.2 2005/11/19 15:37:10 naddy Exp $
|
||||
XtToolkitInitialize();
|
||||
|
||||
appc = XtCreateApplicationContext();
|
||||
@@ -123,12 +127,12 @@ top_setup(argc, argv)
|
||||
@@ -123,12 +128,12 @@ top_setup(argc, argv)
|
||||
XtSetValues(top_shell, &arg, 1);
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user