summaryrefslogtreecommitdiff
path: root/science/netcdf4/files/patch-ncvalues.h
diff options
context:
space:
mode:
authorKirill Ponomarev <krion@FreeBSD.org>2004-03-20 17:25:07 +0000
committerKirill Ponomarev <krion@FreeBSD.org>2004-03-20 17:25:07 +0000
commitd287666fd9fb434a0f9727542b0e7ce0591c890d (patch)
tree0ef197c38372c3f17153f4d9cec3f7cc08b23b74 /science/netcdf4/files/patch-ncvalues.h
parent- Utilize USE_ICONV (diff)
- Update to version 3.5.1
PR: ports/64507 Submitted by: Ports Fury
Notes
Notes: svn path=/head/; revision=104748
Diffstat (limited to 'science/netcdf4/files/patch-ncvalues.h')
-rw-r--r--science/netcdf4/files/patch-ncvalues.h42
1 files changed, 0 insertions, 42 deletions
diff --git a/science/netcdf4/files/patch-ncvalues.h b/science/netcdf4/files/patch-ncvalues.h
deleted file mode 100644
index a6d8be1c9428..000000000000
--- a/science/netcdf4/files/patch-ncvalues.h
+++ /dev/null
@@ -1,42 +0,0 @@
---- cxx/ncvalues.h.orig Wed Oct 28 18:10:16 1998
-+++ cxx/ncvalues.h Sat Feb 7 14:03:13 2004
-@@ -10,12 +10,9 @@
- #ifndef Ncvalues_def
- #define Ncvalues_def
-
--#include <iostream.h>
--#ifdef STRSTREAM_H_SPEC
--# include STRSTREAM_H_SPEC
--#else
--# include <strstream.h>
--#endif
-+#include <bitset>
-+#include <iostream>
-+#include <sstream>
- #include <limits.h>
- #include <string.h>
- #include "netcdf.h"
-@@ -24,6 +21,8 @@
-
- #define NC_UNSPECIFIED ((nc_type)0)
-
-+using namespace std;
-+
- enum NcType
- {
- ncNoType = NC_UNSPECIFIED,
-@@ -219,9 +218,12 @@
- #define as_string_implement(TYPE) \
- char* NcVal(TYPE)::as_string( long n ) const \
- { \
-- char* s = new char[32]; \
-- ostrstream ostr(s, sizeof(s)); \
-+ static char s[32]; \
-+ ostringstream ostr; \
- ostr << the_values[n] << ends; \
-+ std::string data( ostr.str() ); \
-+ strncpy( s, data.data(), sizeof(s)-1); \
-+ s[ sizeof(s)-1 ] = 0; \
- return s; \
- }
-