Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0a16068

Browse files
committed
Issue #1894
Add PXAT/EXAT arguments to SET command.
1 parent 55bf020 commit 0a16068

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

redis_commands.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1594,7 +1594,11 @@ int redis_set_cmd(INTERNAL_FUNCTION_PARAMETERS, RedisSock *redis_sock,
15941594
ZEND_HASH_FOREACH_STR_KEY_VAL(kt, zkey, v) {
15951595
ZVAL_DEREF(v);
15961596
/* Detect PX or EX argument and validate timeout */
1597-
if (zkey && (ZSTR_STRICMP_STATIC(zkey, "EX") || ZSTR_STRICMP_STATIC(zkey, "PX"))) {
1597+
if (zkey && (ZSTR_STRICMP_STATIC(zkey, "EX") ||
1598+
ZSTR_STRICMP_STATIC(zkey, "PX") ||
1599+
ZSTR_STRICMP_STATIC(zkey, "EXAT") ||
1600+
ZSTR_STRICMP_STATIC(zkey, "PXAT"))
1601+
) {
15981602
exp_set = 1;
15991603

16001604
/* Set expire type */

0 commit comments

Comments
 (0)