Check for http_session_vars != NULL.

This commit is contained in:
Sascha Schumann 2001-06-08 11:45:53 +00:00
parent dfa35a78e6
commit b31801b249

View File

@ -270,8 +270,10 @@ int php_get_session_var(char *name, size_t namelen, zval ***state_var PLS_DC PSL
HashTable *ht = &EG(symbol_table);
if (!PG(register_globals))
ht = Z_ARRVAL_P(PS(http_session_vars));
ht = PS(http_session_vars) ? Z_ARRVAL_P(PS(http_session_vars)) : NULL;
if (!ht) return NULL;
return zend_hash_find(ht, name, namelen + 1, (void **)state_var);
}