• antirez's avatar
    TTL / PTTL commands: two bugs fixed. · 873f328f
    antirez authored
    This commit fixes two corner cases for the TTL command.
    
    1) When the key was already logically expired (expire time older
    than current time) the command returned -1 instead of -2.
    
    2) When the key was existing and the expire was found to be exactly 0
    (the key was just about to expire), the command reported -1 (that is, no
    expire) instead of a TTL of zero (that is, about to expire).
    873f328f
db.c 24.1 KB