[Android] [PATCH 3/3] jni: myVm can be static

Thomas Guillem tom at gllm.fr
Tue Oct 14 11:36:54 CEST 2014


Invalid patch, forgot to cleanup my patches directory, sorry.

On Tue, Oct 14, 2014, at 11:35, Thomas Guillem wrote:
> ---
>  vlc-android/jni/libvlcjni-medialist.c | 3 ---
>  vlc-android/jni/libvlcjni.c           | 2 +-
>  2 files changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/vlc-android/jni/libvlcjni-medialist.c
> b/vlc-android/jni/libvlcjni-medialist.c
> index f782f96..257fadc 100644
> --- a/vlc-android/jni/libvlcjni-medialist.c
> +++ b/vlc-android/jni/libvlcjni-medialist.c
> @@ -28,9 +28,6 @@
>  #define LOG_TAG "VLC/JNI/MediaList"
>  #include "log.h"
>  
> -/** Unique Java VM instance, as defined in libvlcjni.c */
> -extern JavaVM *myVm;
> -
>  struct stopped_monitor {
>      pthread_mutex_t doneMutex;
>      pthread_cond_t doneCondVar;
> diff --git a/vlc-android/jni/libvlcjni.c b/vlc-android/jni/libvlcjni.c
> index 9c28442..2b3a272 100644
> --- a/vlc-android/jni/libvlcjni.c
> +++ b/vlc-android/jni/libvlcjni.c
> @@ -115,7 +115,7 @@ static void releaseMediaPlayer(JNIEnv *env, jobject
> thiz)
>   * Note: It's okay to use a static variable for the VM pointer since
>   there
>   * can only be one instance of this shared library in a single VM
>   */
> -JavaVM *myVm;
> +static JavaVM *myVm;
>  
>  static jobject eventHandlerInstance = NULL;
>  
> -- 
> 2.1.0
> 


More information about the Android mailing list