Skip to content

ULONG_MAX-(1024*64)' is not true #2035

Closed

Description

@lmagine

I received this error message during replication and data mass inserting..
use redis for Windows

=== REDIS BUG REPORT START: Cut & paste starting from here ===
[2472] 30 Sep 15:07:38.848 # === ASSERTION FAILED ===
[2472] 30 Sep 15:07:38.848 # ==> ..\src\networking.c:1778 'c->reply_bytes < ULONG_MAX-(1024*64)' is not true

Activity

  1. mattsta commented on Sep 30, 2014

    @mattsta
    Contributor

    That means you've generated a 4 GB return value, which isn't supported by Redis.

    The only solution is to use fewer operations per connection.

  2. antirez commented on Sep 30, 2014

    @antirez
    Contributor

    Or there is a bug in the Windows port that breaks the computation of c->reply_bytes, which is why this assert is there. It helps to catch computation errors where the counter wraps backward to big numbers.

  3. jepickett commented on Sep 30, 2014

    @jepickett

    This is an ABI difference between 64-bit Windows and 64-bit Posix systems. long on x64 Windows is 32-bits(LLP64), while being a 64-bit value in Posix operating systems(LP64). Thus ULONG_MAX is defined as 0xffffffffUL on Windows. I am working towards creating an ABI portability layer in the Windows version of Redis.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions