Fix unused variable warnings.
Fix memory leak in platform_android.c.

Use static storage instead.