Properly initialized mSaveDepth in JSAutoSuspendRequest, r=sayrer.

This commit is contained in:
Ben Turner 2008-09-08 15:09:41 -07:00
parent 3c106c861e
commit c6eb5d4c06

View File

@ -455,7 +455,7 @@ class JSAutoRequest {
class JSAutoSuspendRequest {
public:
JSAutoSuspendRequest(JSContext *cx) : mContext(cx) {
JSAutoSuspendRequest(JSContext *cx) : mContext(cx), mSaveDepth(0) {
if (mContext) {
mSaveDepth = JS_SuspendRequest(mContext);
}