You are viewing a plain text version of this content. The canonical link for it is here.
Posted to kato-commits@incubator.apache.org by mo...@apache.org on 2009/09/30 09:50:08 UTC

svn commit: r820231 - in /incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native: cjvmti.c include/cjvmti.h

Author: monteith
Date: Wed Sep 30 09:50:07 2009
New Revision: 820231

URL: http://svn.apache.org/viewvc?rev=820231&view=rev
Log:
Fixup 64bit types for Linux.

Modified:
    incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/cjvmti.c
    incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/include/cjvmti.h

Modified: incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/cjvmti.c
URL: http://svn.apache.org/viewvc/incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/cjvmti.c?rev=820231&r1=820230&r2=820231&view=diff
==============================================================================
--- incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/cjvmti.c (original)
+++ incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/cjvmti.c Wed Sep 30 09:50:07 2009
@@ -353,7 +353,7 @@
 int initAgent(){
 	static int dumpCount;
 	time_t creationTime;
-	__int64 longCreationTime;
+	INT64 longCreationTime;
 	struct tm  * dumpTime;
 	char fileName[50];
 	int nameType = 0; // Switches between timestamping the file and not
@@ -392,8 +392,8 @@
 	fwrite(&endianCheck, sizeof(int), 1, variableFile);
 	fprintf(variableFile, "CJVMTI V0.01");
 
-	longCreationTime = (_int64) creationTime; // Ensure that time is written as a long long.
-	fwrite(&longCreationTime, sizeof(_int64), 1, variableFile);
+	longCreationTime = (INT64) creationTime; // Ensure that time is written as a long long.
+	fwrite(&longCreationTime, sizeof(INT64), 1, variableFile);
 	dumpCount++;
 	return 1;
 }

Modified: incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/include/cjvmti.h
URL: http://svn.apache.org/viewvc/incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/include/cjvmti.h?rev=820231&r1=820230&r2=820231&view=diff
==============================================================================
--- incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/include/cjvmti.h (original)
+++ incubator/kato/trunk/org.apache.kato/kato.native/kato.native.cjvmti/src/main/native/include/cjvmti.h Wed Sep 30 09:50:07 2009
@@ -43,6 +43,9 @@
 #define FTELL(x) ftello((x))
 #define FGETPOS(x,y) (*(y))=ftello((x))
 #define FSETPOS(x,y) fseeko((x), (*(y)), SEEK_SET)
+#include <stdint.h>
+
+typedef int64_t INT64;
 #elif   __aix__
 #define FPOS_T off_t
 #define FSEEK(x,y,z) fseeko((x),(y),(z))
@@ -59,7 +62,7 @@
 /* Prototypes for 64 bit functions */
 extern __int64 _ftelli64(FILE *stream);
 extern int _fseeki64(FILE *stream, __int64 offset, int origin);
-
+typedef _int64 INT64;
 #else
 #error "unable to compile on this platform"
 #endif