From 745d6672eb3faae4862311b7d98bb513d8b3fa05 Mon Sep 17 00:00:00 2001 From: Stefan Kieszkowski <85728496+stefankiesz@users.noreply.github.com> Date: Mon, 15 Apr 2024 10:33:00 -0700 Subject: [PATCH] Fix typos, build issues --- .../kinesis/video/producer/jni/Parameters.cpp | 14 +++++++------- .../kinesis/video/producer/jni/Parameters.h | 1 + 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/JNI/com/amazonaws/kinesis/video/producer/jni/Parameters.cpp b/src/JNI/com/amazonaws/kinesis/video/producer/jni/Parameters.cpp index ef7dbf4f..e4b63ee1 100644 --- a/src/JNI/com/amazonaws/kinesis/video/producer/jni/Parameters.cpp +++ b/src/JNI/com/amazonaws/kinesis/video/producer/jni/Parameters.cpp @@ -291,7 +291,7 @@ BOOL setClientInfo(JNIEnv *env, jobject clientInfo, PClientInfo pClientInfo) { return STATUS_FAILED(retStatus) ? FALSE : TRUE; } -VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRetryStrategy pKvsRetryStrategy) +VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategy, PKvsRetryStrategy pKvsRetryStrategy) { jmethodID methodId = NULL; jclass cls = NULL; @@ -312,7 +312,7 @@ VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRet methodId = env->GetMethodID(cls, "getRetryStrategy", "()Lcom/amazonaws/kinesisvideo/producer/RetryStrategy"); if (methodId == NULL) { DLOGW("Couldn't find method id getRetryStrategy, setting pRetryStrategy to null."); - pkvsRetryStrategy->pRetryStrategy = NULL; + pKvsRetryStrategy->pRetryStrategy = NULL; } else { // Set to Java class or member once we implement Java support. } @@ -320,7 +320,7 @@ VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRet methodId = env->GetMethodID(cls, "getRetryStrategyConfig", "()Lcom/amazonaws/kinesisvideo/producer/RetryStrategyConfig"); if (methodId == NULL) { DLOGW("Couldn't find method id getRetryStrategyConfig, setting pRetryStrategyConfig to null."); - pkvsRetryStrategy->pRetryStrategyConfig = NULL; + pKvsRetryStrategy->pRetryStrategyConfig = NULL; } else { // Set to Java class or member once we implement Java support. } @@ -328,7 +328,7 @@ VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRet methodId = env->GetMethodID(cls, "getretryStrategyType", "()Lcom/amazonaws/kinesisvideo/producer/RetryStrategyType"); if (methodId == NULL) { DLOGW("Couldn't find method id getretryStrategyType, setting retryStrategyType to EXPONENTIAL_BACKOFF_WAIT."); - pkvsRetryStrategy->pRetryStrategy = KVS_RETRY_STRATEGY_EXPONENTIAL_BACKOFF_WAIT; + pKvsRetryStrategy->pRetryStrategy = NULL; } else { // Set to Java class or member once we implement Java support. } @@ -337,9 +337,9 @@ VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRet CleanUp: if (nullKvsRetryStrategy) { DLOGI("Setting kvsRetryStrategy members to NULL/default values."); - pkvsRetryStrategy->pRetryStrategy = NULL; - pkvsRetryStrategy->pRetryStrategyConfig = NULL; - pkvsRetryStrategy->pRetryStrategy = KVS_RETRY_STRATEGY_EXPONENTIAL_BACKOFF_WAIT; + pKvsRetryStrategy->pRetryStrategy = NULL; + pKvsRetryStrategy->pRetryStrategyConfig = NULL; + pKvsRetryStrategy->pRetryStrategy = NULL; } } diff --git a/src/JNI/include/com/amazonaws/kinesis/video/producer/jni/Parameters.h b/src/JNI/include/com/amazonaws/kinesis/video/producer/jni/Parameters.h index e962b17c..9f84e73f 100644 --- a/src/JNI/include/com/amazonaws/kinesis/video/producer/jni/Parameters.h +++ b/src/JNI/include/com/amazonaws/kinesis/video/producer/jni/Parameters.h @@ -18,5 +18,6 @@ BOOL releaseStreamDataBuffer(JNIEnv* env, jobject dataBuffer, UINT32 offset, PBY BOOL setTags(JNIEnv *env, jobjectArray tagArray, PTag* ppTags, PUINT32 pTagCount); VOID releaseTags(PTag tags); VOID setKvsRetryStrategyCallbacks(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRetryStrategyCallbacks pKvsRetryStrategyCallbacks); +VOID setKvsRetryStrategy(JNIEnv *env, jobject kvsRetryStrategyCallbacks, PKvsRetryStrategy pKvsRetryStrategy); #endif // __KINESIS_VIDEO_PARAMETERS_CONVERSION_H__