Skip to content

Commit

Permalink
constify JNINativeMethod tables
Browse files Browse the repository at this point in the history
  • Loading branch information
thestinger committed Sep 7, 2021
1 parent e9f2cf8 commit e41f1d7
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion nci/jni/NativeLlcpConnectionlessSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ static jboolean nativeLlcpConnectionlessSocket_doClose(JNIEnv* e, jobject o) {
** Description: JNI functions
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doSendTo", "(I[B)Z", (void*)nativeLlcpConnectionlessSocket_doSendTo},
{"doReceiveFrom", "(I)Lcom/android/nfc/LlcpPacket;",
(void*)nativeLlcpConnectionlessSocket_doReceiveFrom},
Expand Down
2 changes: 1 addition & 1 deletion nci/jni/NativeLlcpServiceSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ static jboolean nativeLlcpServiceSocket_doClose(JNIEnv* e, jobject o) {
** Description: JNI functions
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doAccept", "(III)Lcom/android/nfc/dhimpl/NativeLlcpSocket;",
(void*)nativeLlcpServiceSocket_doAccept},
{"doClose", "()Z", (void*)nativeLlcpServiceSocket_doClose},
Expand Down
2 changes: 1 addition & 1 deletion nci/jni/NativeLlcpSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ static jint nativeLlcpSocket_doGetRemoteSocketRW(JNIEnv* e, jobject o) {
** Description: JNI functions
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doConnect", "(I)Z", (void*)nativeLlcpSocket_doConnect},
{"doConnectBy", "(Ljava/lang/String;)Z",
(void*)nativeLlcpSocket_doConnectBy},
Expand Down
2 changes: 1 addition & 1 deletion nci/jni/NativeNfcManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2001,7 +2001,7 @@ static jstring nfcManager_doGetNfaStorageDir(JNIEnv* e, jobject o) {
** JNI functions for android-4.0.1_r1
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doDownload", "()Z", (void*)nfcManager_doDownload},

{"initializeNativeStructure", "()Z", (void*)nfcManager_initNativeStruc},
Expand Down
2 changes: 1 addition & 1 deletion nci/jni/NativeNfcTag.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1850,7 +1850,7 @@ void nativeNfcTag_releaseRfInterfaceMutexLock() {
** JNI functions for Android 4.0.3
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doConnect", "(I)I", (void*)nativeNfcTag_doConnect},
{"doDisconnect", "()Z", (void*)nativeNfcTag_doDisconnect},
{"doReconnect", "()I", (void*)nativeNfcTag_doReconnect},
Expand Down
2 changes: 1 addition & 1 deletion nci/jni/NativeP2pDevice.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ static jboolean nativeP2pDeviceDoSend(JNIEnv*, jobject, jbyteArray) {
** Description: JNI functions
**
*****************************************************************************/
static JNINativeMethod gMethods[] = {
static const JNINativeMethod gMethods[] = {
{"doConnect", "()Z", (void*)nativeP2pDeviceDoConnect},
{"doDisconnect", "()Z", (void*)nativeP2pDeviceDoDisconnect},
{"doTransceive", "([B)[B", (void*)nativeP2pDeviceDoTransceive},
Expand Down

0 comments on commit e41f1d7

Please sign in to comment.