- make this class usable, mostly by fixing typos
[m6w6/ext-http] / http_filter_api.c
index 35cff1cdb2b837937cc6418c26ebd2e8462e260d..2553d681113728bbbe727deb95fc2c7b4ad91fe3 100644 (file)
@@ -74,7 +74,7 @@ PHP_MINIT_FUNCTION(http_filter)
                php_stream_bucket_append(buckets_out, __buck TSRMLS_CC); \
        }
 
-typedef struct {
+typedef struct _http_chunked_decode_filter_buffer_t {
        phpstr  buffer;
        ulong   hexlen;
 } HTTP_FILTER_BUFFER(chunked_decode);
@@ -165,8 +165,8 @@ static HTTP_FILTER_FUNCTION(chunked_decode)
                        
                        /* ignore preceeding CRLFs (too loose?) */
                        while (off < PHPSTR_LEN(buffer) && (
-                                       PHPSTR_VAL(buffer)[off] == 0xa || 
-                                       PHPSTR_VAL(buffer)[off] == 0xd)) {
+                                       PHPSTR_VAL(buffer)[off] == '\n' || 
+                                       PHPSTR_VAL(buffer)[off] == '\r')) {
                                ++off;
                        }
                        if (off) {