From 128eb0578f147765e9613a65bcb7e71d95ea5b0e Mon Sep 17 00:00:00 2001 From: "mscott%netscape.com" Date: Wed, 5 Apr 2000 04:00:13 +0000 Subject: [PATCH] Pass the address of the jsval instead of the value (which was null). This helps allow you to access xp-connect objects from xbl. r=hyatt --- content/xbl/src/nsXBLBinding.cpp | 6 +++--- layout/xbl/src/nsXBLBinding.cpp | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/content/xbl/src/nsXBLBinding.cpp b/content/xbl/src/nsXBLBinding.cpp index b15fe414a565..45d5a3acb7b0 100644 --- a/content/xbl/src/nsXBLBinding.cpp +++ b/content/xbl/src/nsXBLBinding.cpp @@ -829,17 +829,17 @@ nsXBLBinding::InstallProperties(nsIContent* aBoundElement) if (!answer.IsEmpty()) { // Evaluate our script and obtain a value. - jsval* result = nsnull; + jsval result = nsnull; PRBool undefined; rv = context->EvaluateStringWithValue(answer, mScriptObject, nsnull, nsnull, 0, nsnull, - (void*)result, &undefined); + (void*) &result, &undefined); if (!undefined) { // Define that value as a property rv = ::JS_DefineUCProperty(cx, (JSObject*)mScriptObject, name.GetUnicode(), - name.Length(), *result, + name.Length(), result, nsnull, nsnull, attrs); } diff --git a/layout/xbl/src/nsXBLBinding.cpp b/layout/xbl/src/nsXBLBinding.cpp index b15fe414a565..45d5a3acb7b0 100644 --- a/layout/xbl/src/nsXBLBinding.cpp +++ b/layout/xbl/src/nsXBLBinding.cpp @@ -829,17 +829,17 @@ nsXBLBinding::InstallProperties(nsIContent* aBoundElement) if (!answer.IsEmpty()) { // Evaluate our script and obtain a value. - jsval* result = nsnull; + jsval result = nsnull; PRBool undefined; rv = context->EvaluateStringWithValue(answer, mScriptObject, nsnull, nsnull, 0, nsnull, - (void*)result, &undefined); + (void*) &result, &undefined); if (!undefined) { // Define that value as a property rv = ::JS_DefineUCProperty(cx, (JSObject*)mScriptObject, name.GetUnicode(), - name.Length(), *result, + name.Length(), result, nsnull, nsnull, attrs); }