{{END_KNOWN_TYPES, NULL, NULL, NULL}, guess_zval_convert, guess_xml_convert}
};
+int numDefaultEncodings = sizeof(defaultEncoding)/sizeof(encode);
+
+
void whiteSpace_replace(char* str)
{
while (*str != '\0') {
{
sdlTypePtr *tmp;
- if (zend_hash_find(ptr_map, (char *)(*type), sizeof(sdlTypePtr), (void**)&tmp) == SUCCESS) {
+ if (zend_hash_find(ptr_map, (char *)type, sizeof(sdlTypePtr), (void**)&tmp) == SUCCESS) {
*type = *tmp;
} else {
zend_hash_next_index_insert(bp_types, (void*)&type, sizeof(sdlTypePtr*), NULL);
encodePtr *tmp;
/* do not process defaultEncoding's here */
- if ((*enc)->details.sdl_type == NULL) {
+ if ((*enc) >= defaultEncoding && (*enc) < defaultEncoding + numDefaultEncodings) {
return;
}
- if (zend_hash_find(ptr_map, (char *)(*enc), sizeof(encodePtr), (void**)&tmp) == SUCCESS) {
+ if (zend_hash_find(ptr_map, (char *)enc, sizeof(encodePtr), (void**)&tmp) == SUCCESS) {
*enc = *tmp;
} else {
zend_hash_next_index_insert(bp_encoders, (void*)&enc, sizeof(encodePtr*), NULL);
}
/* we do not want to process defaultEncoding's here */
- if (pattr->encode && pattr->encode->details.sdl_type) {
+ if (pattr->encode) {
make_persistent_sdl_encoder_ref(&pattr->encode, ptr_map, bp_encoders);
}
}
/* we do not want to process defaultEncoding's here */
- if (ptype->encode && ptype->encode->details.sdl_type) {
+ if (ptype->encode) {
make_persistent_sdl_encoder_ref(&ptype->encode, ptr_map, bp_encoders);
}