Skip to content

Commit cf62ee0

Browse files
committed
Merge pull request #631
2 parents 0571e4b + 6175972 commit cf62ee0

File tree

7 files changed

+3
-37
lines changed

7 files changed

+3
-37
lines changed

.travis.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ php:
44
- 7.0
55
- 5.6
66
- 5.5
7-
- 5.4
87

98
env:
109
global:

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ releasing the `vX.Y` branch as X.Y.Z).
9696

9797
### Ensure PHP version compatibility
9898

99-
Ensure that the extension compiles on PHP 5.4, 5.5, 5.6, and 7.0. Be sure to
99+
Ensure that the extension compiles on PHP 5.5, 5.6, 7.0, and 7.1. Be sure to
100100
test both ZTS and non-ZTS builds for PHP 5.x.
101101

102102
### Ensure Windows compatibility

phongo_compat.h

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -43,28 +43,6 @@
4343
# include <Zend/zend_string.h>
4444
#endif
4545

46-
#if PHP_VERSION_ID >= 50500
47-
#define ITERATOR_GET_CURRENT_KEY(it, z) \
48-
(it).funcs->get_current_key(&(it), z TSRMLS_CC);
49-
#else
50-
#define ITERATOR_GET_CURRENT_KEY(it, z) \
51-
{ \
52-
char *str_key; \
53-
uint str_key_len; \
54-
ulong int_key; \
55-
switch ((it).funcs->get_current_key(&(it), &str_key, &str_key_len, &int_key TSRMLS_CC)) { \
56-
case HASH_KEY_IS_LONG: \
57-
ZVAL_LONG(z, int_key); \
58-
break; \
59-
case HASH_KEY_IS_STRING: \
60-
ZVAL_STRINGL(z, str_key, str_key_len-1, 0); \
61-
break; \
62-
default: \
63-
RETURN_NULL(); \
64-
} \
65-
}
66-
#endif
67-
6846
#if defined(__GNUC__)
6947
# define ARG_UNUSED __attribute__ ((unused))
7048
#else

src/MongoDB/Cursor.c

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -66,22 +66,12 @@ static int php_phongo_cursor_iterator_valid(zend_object_iterator *iter TSRMLS_DC
6666
return FAILURE;
6767
} /* }}} */
6868

69-
#if PHP_VERSION_ID < 50500
70-
static int php_phongo_cursor_iterator_get_current_key(zend_object_iterator *iter, char **str_key, uint *str_key_len, ulong *int_key TSRMLS_DC) /* {{{ */
71-
{
72-
php_phongo_cursor_t *cursor = ((php_phongo_cursor_iterator *)iter)->cursor;
73-
74-
*int_key = (ulong) cursor->current;
75-
return HASH_KEY_IS_LONG;
76-
} /* }}} */
77-
#else
7869
static void php_phongo_cursor_iterator_get_current_key(zend_object_iterator *iter, zval *key TSRMLS_DC) /* {{{ */
7970
{
8071
php_phongo_cursor_t *cursor = ((php_phongo_cursor_iterator *)iter)->cursor;
8172

8273
ZVAL_LONG(key, cursor->current);
8374
} /* }}} */
84-
#endif
8575

8676
#if PHP_VERSION_ID < 70000
8777
static void php_phongo_cursor_iterator_get_current_data(zend_object_iterator *iter, zval ***data TSRMLS_DC) /* {{{ */

tests/bson/bson-utcdatetime-006.phpt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
--TEST--
22
MongoDB\BSON\UTCDateTime construction from DateTimeImmutable
3-
--SKIPIF--
4-
<?php if (!version_compare(phpversion(), "5.5", '>=')) echo "skip >= PHP 5.5 needed\n"; ?>
53
--INI--
64
date.timezone=UTC
75
--FILE--

tests/bson/bson-utcdatetimeinterface-002.phpt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
--TEST--
22
MongoDB\BSON\UTCDateTimeInterface example with MongoDB\BSON\TypeWrapper
3+
--INI--
4+
date.timezone=UTC
35
--FILE--
46
<?php
57

tests/cursor/bug0732-001.phpt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
--TEST--
22
PHPC-732: Possible mongoc_client_t use-after-free with Cursor wrapped in generator
33
--SKIPIF--
4-
<?php if (PHP_VERSION_ID < 50500) exit("skip PHP 5.5 is required for generators"); ?>
54
<?php require __DIR__ . "/../utils/basic-skipif.inc"; ?>
65
<?php NEEDS('STANDALONE'); CLEANUP(STANDALONE); ?>
76
--FILE--

0 commit comments

Comments
 (0)