From 25cfdb8ee1fe2f6b1bb7b9d4aee6f33bdc90dbd1 Mon Sep 17 00:00:00 2001 From: "nicolson%netscape.com" Date: Thu, 7 Mar 2002 01:59:58 +0000 Subject: [PATCH] Fix 129389: Algorithm.c treats oidIndex as short when it should be int. git-svn-id: svn://10.0.0.236/trunk@116018 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/security/jss/org/mozilla/jss/crypto/Algorithm.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/mozilla/security/jss/org/mozilla/jss/crypto/Algorithm.c b/mozilla/security/jss/org/mozilla/jss/crypto/Algorithm.c index 5ee754539d0..40b70f79289 100644 --- a/mozilla/security/jss/org/mozilla/jss/crypto/Algorithm.c +++ b/mozilla/security/jss/org/mozilla/jss/crypto/Algorithm.c @@ -160,11 +160,11 @@ JSS_getOidTagFromAlg(JNIEnv *env, jobject alg) * The index obtained from the algorithm, or -1 if an exception was * thrown. */ -static jshort +static jint getAlgIndex(JNIEnv *env, jobject alg) { jclass algClass; - jshort index=-1; + jint index=-1; jfieldID indexField; PR_ASSERT(env!=NULL && alg!=NULL); @@ -189,7 +189,7 @@ getAlgIndex(JNIEnv *env, jobject alg) goto finish; } - index = (*env)->GetShortField(env, alg, indexField); + index = (*env)->GetIntField(env, alg, indexField); PR_ASSERT( (index >= 0) && (index < NUM_ALGS) ); finish: @@ -213,7 +213,7 @@ finish: static PRStatus getAlgInfo(JNIEnv *env, jobject alg, JSS_AlgInfo *info) { - jshort index; + jint index; PRStatus status; PR_ASSERT(env!=NULL && alg!=NULL && info!=NULL);