add required patches, unbroken

This commit is contained in:
rohee 1999-11-01 22:06:48 +00:00
parent 7c5faefb28
commit f6d05fb838
12 changed files with 187 additions and 3 deletions

View File

@ -1,6 +1,4 @@
# $OpenBSD: Makefile,v 1.10 1999/10/29 10:01:06 turan Exp $
BROKEN= c syntax errors
# $OpenBSD: Makefile,v 1.11 1999/11/01 22:06:48 rohee Exp $
DISTNAME= abuse-2.0
CATEGORIES= games x11

View File

@ -1,3 +1,7 @@
$OpenBSD: patch-aa,v 1.2 1999/11/01 22:06:48 rohee Exp $
Fix a possible buffer overflow...
*** abuse/src/net/mac/tcpip.c.orig Sat Apr 25 20:42:09 1998
--- abuse/src/net/mac/tcpip.c Sat Apr 25 20:42:33 1998
***************

View File

@ -1,3 +1,7 @@
$OpenBSD: patch-ab,v 1.2 1999/11/01 22:06:48 rohee Exp $
bsd.port.mk set INSTALL to the good value...
--- configure.old Mon Jul 7 11:23:01 1997
+++ configure Tue Jun 9 22:24:33 1998
@@ -988,10 +988,10 @@

View File

@ -1,3 +1,5 @@
$OpenBSD: patch-ac,v 1.2 1999/11/01 22:06:48 rohee Exp $
--- abuse/Makefile.in.orig Wed Jul 9 00:55:21 1997
+++ abuse/Makefile.in Sat Aug 29 04:31:24 1998
@@ -37,10 +37,10 @@

View File

@ -1,3 +1,5 @@
$OpenBSD: patch-ad,v 1.2 1999/11/01 22:06:48 rohee Exp $
--- abuse/abuse.in.orig Wed Jul 9 00:54:43 1997
+++ abuse/abuse.in Sat Aug 29 04:26:04 1998
@@ -27,5 +27,5 @@

View File

@ -0,0 +1,25 @@
$OpenBSD: patch-dev.c,v 1.1 1999/11/01 22:06:48 rohee Exp $
"foo" is now a 'const char *' in C++ and thus can't be passed to a method
requiring a 'char *'.
--- abuse/src/dev.c.orig Wed Oct 20 23:18:11 1999
+++ abuse/src/dev.c Wed Oct 20 23:22:47 1999
@@ -2057,7 +2057,7 @@
{
if (!mess_win)
{
- mess_win=file_dialog(eh,symbol_str("level_name"),current_level ? current_level->name() : "",
+ mess_win=file_dialog(eh,symbol_str("level_name"),current_level ? current_level->name() : (char *) "",
ID_LEVEL_LOAD_OK,symbol_str("ok_button"),ID_CANCEL,symbol_str("cancel_button"),
symbol_str("FILENAME"),ID_MESS_STR1);
eh->grab_focus(mess_win);
@@ -2093,7 +2093,7 @@
{
if (!mess_win)
{
- mess_win=file_dialog(eh,symbol_str("saveas_name"),current_level ? current_level->name() : "untitled.spe",
+ mess_win=file_dialog(eh,symbol_str("saveas_name"),current_level ? current_level->name() : (char *) "untitled.spe",
ID_LEVEL_SAVEAS_OK,symbol_str("ok_button"),
ID_CANCEL,symbol_str("cancel_button"),
symbol_str("FILENAME"),ID_MESS_STR1);

View File

@ -0,0 +1,15 @@
$OpenBSD: patch-jnet.c,v 1.1 1999/11/01 22:06:48 rohee Exp $
Using the good type to make it compile with g++-2.9.x
--- imlib/port/unix/jnet.c.orig Fri Oct 29 00:07:47 1999
+++ imlib/port/unix/jnet.c Fri Oct 29 00:09:28 1999
@@ -146,7 +146,7 @@
if (FD_ISSET(fd,&set))
{
- int len=sizeof(sockaddr_in);
+ socklen_t len=sizeof(sockaddr_in);
int new_fd=accept(fd, (struct sockaddr *) &host, &len);
if (new_fd<0)
{

View File

@ -0,0 +1,24 @@
$OpenBSD: patch-nfclient.c,v 1.1 1999/11/01 22:06:48 rohee Exp $
Make the method prototypes match the new superclass
--- abuse/src/nfclient.c.orig Fri Oct 29 00:26:21 1999
+++ abuse/src/nfclient.c Fri Oct 29 00:27:59 1999
@@ -32,7 +32,7 @@
virtual int open_failure();
virtual int unbuffered_read(void *buf, size_t count); // returns number of bytes read
int new_read(void *buf, size_t count); // returns number of bytes read
- virtual int unbuffered_write(void *buf, size_t count); // returns number of bytes written
+ virtual int unbuffered_write(const void *buf, size_t count); // returns number of bytes written
virtual int unbuffered_seek(long offset, int whence); // whence=SEEK_SET, SEEK_CUR, SEEK_END, ret=0=success
virtual int unbuffered_tell();
virtual int file_size();
@@ -143,7 +143,7 @@
else return 0;
}
-int nfs_file::unbuffered_write(void *buf, size_t count) // returns number of bytes written
+int nfs_file::unbuffered_write(const void *buf, size_t count) // returns number of bytes written
{
if (local)
return local->write(buf,count);

View File

@ -0,0 +1,33 @@
$OpenBSD: patch-specs.c,v 1.1 1999/11/01 22:06:48 rohee Exp $
Need const because of stricter type checking with g++-2.9+...
--- imlib/specs.c.orig Tue Jul 8 12:00:50 1997
+++ imlib/specs.c Thu Oct 28 23:52:45 1999
@@ -180,7 +180,7 @@
}
-int bFILE::write(void *buf, size_t count) // returns number of bytes written
+int bFILE::write(const void *buf, size_t count) // returns number of bytes written
{
if (allow_write_buffering())
{
@@ -359,7 +359,7 @@
public :
virtual int open_failure() { return 1; }
virtual int unbuffered_read(void *buf, size_t count) { return 0; }
- virtual int unbuffered_write(void *buf, size_t count) { return 0; }
+ virtual int unbuffered_write(const void *buf, size_t count) { return 0; }
virtual int unbuffered_seek(long offset, int whence) { return 0; }
virtual int unbuffered_tell() { return 0; }
@@ -523,7 +523,7 @@
return len;
}
-int jFILE::unbuffered_write(void *buf, size_t count)
+int jFILE::unbuffered_write(const void *buf, size_t count)
{
long ret = ::write(fd,(char*)buf,count);
current_offset += ret;

View File

@ -0,0 +1,37 @@
$OpenBSD: patch-specs.hpp,v 1.1 1999/11/01 22:06:48 rohee Exp $
Need const here...
--- imlib/include/specs.hpp.orig Mon Apr 15 21:25:42 1996
+++ imlib/include/specs.hpp Thu Oct 28 23:47:46 1999
@@ -76,7 +76,7 @@
int flush_writes(); // returns 0 on failure, else # of bytes written
virtual int unbuffered_read(void *buf, size_t count) = 0;
- virtual int unbuffered_write(void *buf, size_t count) = 0;
+ virtual int unbuffered_write(const void *buf, size_t count) = 0;
virtual int unbuffered_tell() = 0;
virtual int unbuffered_seek(long offset, int whence) = 0; // whence=SEEK_SET, SEEK_CUR,
// SEEK_END, ret=0=success
@@ -85,9 +85,9 @@
public :
bFILE();
virtual int open_failure() = 0;
- int read(void *buf, size_t count); // returns number of bytes read, calls unbuffer_read
- int write(void *buf, size_t count); // returns number of bytes written
- int seek(long offset, int whence); // whence=SEEK_SET, SEEK_CUR, SEEK_END, ret=0=success
+ int read(void *buf, size_t count); // returns number of bytes read, calls unbuffer_read
+ int write(const void *buf, size_t count); // returns number of bytes written
+ int seek(long offset, int whence); // whence=SEEK_SET, SEEK_CUR, SEEK_END, ret=0=success
int tell();
virtual int file_size() = 0;
@@ -126,7 +126,7 @@
jFILE(FILE *file_pointer); // assumes fp is at begining of file
virtual int open_failure() { return fd<0; }
virtual int unbuffered_read(void *buf, size_t count); // returns number of bytes read
- virtual int unbuffered_write(void *buf, size_t count); // returns number of bytes written
+ virtual int unbuffered_write(const void *buf, size_t count);// returns number of bytes written
virtual int unbuffered_seek(long offset, int whence); // whence=SEEK_SET, SEEK_CUR,
// SEEK_END, ret=0=success
virtual int unbuffered_tell();

View File

@ -0,0 +1,24 @@
$OpenBSD: patch-tcpip.hpp,v 1.1 1999/11/01 22:06:48 rohee Exp $
Use the good type, stricter type checking now...
--- abuse/src/net/mac/tcpip.hpp.orig Tue Jul 8 01:03:29 1997
+++ abuse/src/net/mac/tcpip.hpp Fri Oct 29 00:23:58 1999
@@ -176,7 +176,7 @@
if (listening)
{
struct sockaddr_in from;
- int addr_len=sizeof(from);
+ socklen_t addr_len=sizeof(from);
int new_fd=::accept(fd,(sockaddr *)&from,&addr_len);
if (new_fd>=0)
{
@@ -200,7 +200,7 @@
if (addr)
{
*addr=new ip_address;
- int addr_size=sizeof(sockaddr_in);
+ socklen_t addr_size=sizeof(sockaddr_in);
tr=recvfrom(fd,buf,size,0, (sockaddr *) &((ip_address *)(*addr))->addr,&addr_size);
} else
tr=recv(fd,buf,size,0);

View File

@ -0,0 +1,16 @@
$OpenBSD: patch-view.c,v 1.1 1999/11/01 22:06:48 rohee Exp $
"foo" is now a 'const char *' in C++ and thus can't be passed to a method
requiring a 'char *'.
--- abuse/src/view.c.orig Wed Oct 20 23:24:07 1999
+++ abuse/src/view.c Wed Oct 20 23:25:13 1999
@@ -179,7 +179,7 @@
#else
char *get_login()
-{ if (cur_user_name[0]) return cur_user_name; else return (getlogin() ? getlogin() : "unknown"); }
+{ if (cur_user_name[0]) return cur_user_name; else return (getlogin() ? getlogin() : (char *) "unknown"); }
#endif