@@ -646,15 +646,18 @@ PHPAPI const char *php_stream_locate_eol(php_stream *stream, zend_string *buf);
646
646
/* pushes an error message onto the stack for a wrapper instance */
647
647
PHPAPI void php_stream_wrapper_log_error (const php_stream_wrapper * wrapper , int options , const char * fmt , ...) PHP_ATTRIBUTE_FORMAT (printf , 3 , 4 );
648
648
649
- #define PHP_STREAM_UNCHANGED 0 /* orig stream was seekable anyway */
650
- #define PHP_STREAM_RELEASED 1 /* newstream should be used; origstream is no longer valid */
651
- #define PHP_STREAM_FAILED 2 /* an error occurred while attempting conversion */
652
- #define PHP_STREAM_CRITICAL 3 /* an error occurred; origstream is in an unknown state; you should close origstream */
649
+ typedef enum {
650
+ PHP_STREAM_UNCHANGED = 0 , /* orig stream was seekable anyway */
651
+ PHP_STREAM_RELEASED = 1 , /* newstream should be used; origstream is no longer valid */
652
+ PHP_STREAM_FAILED = 2 , /* an error occurred while attempting conversion */
653
+ PHP_STREAM_CRITICAL = 3 , /* an error occurred; origstream is in an unknown state; you should close origstream */
654
+ } php_stream_make_seekable_status ;
655
+
653
656
#define PHP_STREAM_NO_PREFERENCE 0
654
657
#define PHP_STREAM_PREFER_STDIO 1
655
658
#define PHP_STREAM_FORCE_CONVERSION 2
656
659
/* DO NOT call this on streams that are referenced by resources! */
657
- PHPAPI int _php_stream_make_seekable (php_stream * origstream , php_stream * * newstream , int flags STREAMS_DC );
660
+ PHPAPI php_stream_make_seekable_status _php_stream_make_seekable (php_stream * origstream , php_stream * * newstream , int flags STREAMS_DC );
658
661
#define php_stream_make_seekable (origstream , newstream , flags ) _php_stream_make_seekable((origstream), (newstream), (flags) STREAMS_CC)
659
662
660
663
/* Give other modules access to the url_stream_wrappers_hash and stream_filters_hash */
0 commit comments