// File: /workspace/github_c_makefile_star2_O0/gplessis[P]dotdeb-redis/src/notify.c
// Function: notifyKeyspaceEvent
void notifyKeyspaceEvent(int type, char *event, robj *key, int dbid) {
    sds chan;
    robj *chanobj, *eventobj;
    int len = -1;
    char buf[24];

    /* If notifications for this class of events are off, return ASAP. */
    if (!(server.notify_keyspace_events & type)) return;

    eventobj = createStringObject(event,strlen(event));

    /* __keyspace@<db>__:<key> <event> notifications. */
    if (server.notify_keyspace_events & NOTIFY_KEYSPACE) {
        chan = sdsnewlen("__keyspace@",11);
        len = ll2string(buf,sizeof(buf),dbid);
        chan = sdscatlen(chan, buf, len);
        chan = sdscatlen(chan, "__:", 3);
        chan = sdscatsds(chan, key->ptr);
        chanobj = createObject(OBJ_STRING, chan);
        pubsubPublishMessage(chanobj, eventobj);
        decrRefCount(chanobj);
    }

    /* __keyevente@<db>__:<event> <key> notifications. */
    if (server.notify_keyspace_events & NOTIFY_KEYEVENT) {
        chan = sdsnewlen("__keyevent@",11);
        if (len == -1) len = ll2string(buf,sizeof(buf),dbid);
        chan = sdscatlen(chan, buf, len);
        chan = sdscatlen(chan, "__:", 3);
        chan = sdscatsds(chan, eventobj->ptr);
        chanobj = createObject(OBJ_STRING, chan);
        pubsubPublishMessage(chanobj, key);
        decrRefCount(chanobj);
    }
    decrRefCount(eventobj);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movl %edi, -0x4(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl $0xffffffff, -0x3c(%rbp) # imm = 0xFFFFFFFF
leaq 0xdb394(%rip), %rax     # 0x1781d8
movl 0x998(%rax), %eax
andl -0x4(%rbp), %eax
cmpl $0x0, %eax
jne 0x9ce57
jmp 0x9cfdd
movq -0x10(%rbp), %rax
movq %rax, -0x68(%rbp)
movq -0x10(%rbp), %rdi
callq 0x264f0
movq -0x68(%rbp), %rdi
movq %rax, %rsi
callq 0x486a0
movq %rax, -0x38(%rbp)
leaq 0xdb359(%rip), %rax     # 0x1781d8
movl 0x998(%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x9cf23
leaq 0xaa74a(%rip), %rdi     # 0x1475e2
movl $0xb, %esi
callq 0x38230
movq %rax, -0x28(%rbp)
leaq -0x60(%rbp), %rdi
movslq -0x1c(%rbp), %rdx
movl $0x18, %esi
callq 0x477e0
movl %eax, -0x3c(%rbp)
movq -0x28(%rbp), %rdi
leaq -0x60(%rbp), %rsi
movslq -0x3c(%rbp), %rdx
callq 0x39040
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
leaq 0xaa713(%rip), %rsi     # 0x1475ee
movl $0x3, %edx
callq 0x39040
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x39110
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rsi
xorl %edi, %edi
callq 0x48480
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x74fa0
movq -0x30(%rbp), %rdi
callq 0x48f70
leaq 0xdb2ae(%rip), %rax     # 0x1781d8
movl 0x998(%rax), %eax
andl $0x2, %eax
cmpl $0x0, %eax
je 0x9cfd4
leaq 0xaa6af(%rip), %rdi     # 0x1475f2
movl $0xb, %esi
callq 0x38230
movq %rax, -0x28(%rbp)
cmpl $-0x1, -0x3c(%rbp)
jne 0x9cf6c
leaq -0x60(%rbp), %rdi
movslq -0x1c(%rbp), %rdx
movl $0x18, %esi
callq 0x477e0
movl %eax, -0x3c(%rbp)
movq -0x28(%rbp), %rdi
leaq -0x60(%rbp), %rsi
movslq -0x3c(%rbp), %rdx
callq 0x39040
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
leaq 0xaa662(%rip), %rsi     # 0x1475ee
movl $0x3, %edx
callq 0x39040
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
movq -0x38(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x39110
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rsi
xorl %edi, %edi
callq 0x48480
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x74fa0
movq -0x30(%rbp), %rdi
callq 0x48f70
movq -0x38(%rbp), %rdi
callq 0x48f70
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nopl (%rax)