Files
pkgsrc-ng/comms/plp/patches/patch-ah
2013-09-26 17:14:40 +02:00

51 lines
1.2 KiB
Plaintext

$NetBSD: patch-ah,v 1.3 2011/12/19 13:44:07 wiz Exp $
--- rfsv/rfsv32.cc.orig 1999-11-02 21:12:47.000000000 +0000
+++ rfsv/rfsv32.cc
@@ -19,10 +19,11 @@
//
// e-mail philip.proudman@btinternet.com
-#include <stream.h>
+#include <iostream>
+using namespace std;
#include <stdlib.h>
-#include <fstream.h>
-#include <iomanip.h>
+#include <fstream>
+#include <iomanip>
#include <time.h>
#include <string.h>
@@ -183,7 +184,7 @@ int rfsv32::dir(const char* dirName, buf
us += modLow;
us /= 1000000;
us -= (1970*365 + 490)*60*60*24;
- long date = us;
+ time_t date = us;
char dateBuff[100];
struct tm *t;
t = gmtime(&date);
@@ -275,10 +276,10 @@ void rfsv32::opErr(long status) {
case BAD_HANDLE:
cerr << "BAD_HANDLE";
break;
- case OVERFLOW:
+ case E_OVERFLOW:
cerr << "OVERFLOW";
break;
- case UNDERFLOW:
+ case E_UNDERFLOW:
cerr << "UNDERFLOW";
break;
case ALREADY_EXISTS:
@@ -455,7 +456,7 @@ int rfsv32::write(const char* localName,
}
unsigned char * buff = new unsigned char [RFSV_SENDLEN];
while (ip &&!ip.eof()) {
- ip.read(buff, RFSV_SENDLEN);
+ ip.read((char *)buff, RFSV_SENDLEN);
bufferStore tmp(buff, ip.gcount());
if (tmp.getLen() == 0) break;
bufferStore a;