added null checking


git-svn-id: svn://10.0.0.236/trunk@54558 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
idk%eng.sun.com
1999-11-29 07:26:37 +00:00
parent dfb64c2671
commit 2a95e241e9

View File

@@ -40,6 +40,9 @@ JNIEXPORT jobject JNICALL Java_org_mozilla_pluglet_mozilla_PlugletTagInfo2Impl_g
*/
JNIEXPORT jstring JNICALL Java_org_mozilla_pluglet_mozilla_PlugletTagInfo2Impl_getAttribute
(JNIEnv *env, jobject jthis, jstring _name) {
if (!_name) {
return NULL;
}
nsIPluginTagInfo2 * info = (nsIPluginTagInfo2*)env->GetLongField(jthis, peerFID);
const char * name = NULL;
if (!(name = env->GetStringUTFChars(_name,NULL))) {