// File: /workspace/github_c_makefile_star2_O0/Genymobile[P]hiredis/test.c
// Function: test_blocking_connection_errors
static void test_blocking_connection_errors(void) {
    redisContext *c;

    test("Returns error when host cannot be resolved: ");
    c = redisConnect((char*)"idontexist.test", 6379);
    test_cond(c->err == REDIS_ERR_OTHER &&
        (strcmp(c->errstr,"Name or service not known") == 0 ||
         strcmp(c->errstr,"Can't resolve: idontexist.test") == 0 ||
         strcmp(c->errstr,"nodename nor servname provided, or not known") == 0 ||
         strcmp(c->errstr,"No address associated with hostname") == 0 ||
         strcmp(c->errstr,"Temporary failure in name resolution") == 0 ||
         strcmp(c->errstr,"hostname nor servname provided, or not known") == 0 ||
         strcmp(c->errstr,"no address associated with name") == 0));
    redisFree(c);

    test("Returns error when the port is not open: ");
    c = redisConnect((char*)"localhost", 1);
    test_cond(c->err == REDIS_ERR_IO &&
        strcmp(c->errstr,"Connection refused") == 0);
    redisFree(c);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movl 0xe562(%rip), %esi      # 0x121c0
addl $0x1, %esi
movl %esi, 0xe559(%rip)      # 0x121c0
leaq 0x94c0(%rip), %rdi      # 0xd12e
movb $0x0, %al
callq 0x20f0
leaq 0x9cdf(%rip), %rdi      # 0xd95b
movb $0x0, %al
callq 0x20f0
leaq 0x9d27(%rip), %rdi      # 0xd9b1
movl $0x18eb, %esi           # imm = 0x18EB
callq 0x6ed0
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x2, (%rax)
jne 0x3d68
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9cd4(%rip), %rsi      # 0xd988
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9cd1(%rip), %rsi      # 0xd9a2
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9cd7(%rip), %rsi      # 0xd9c1
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9ceb(%rip), %rsi      # 0xd9ee
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9cf6(%rip), %rsi      # 0xda12
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9d02(%rip), %rsi      # 0xda37
callq 0x21a0
cmpl $0x0, %eax
je 0x3d58
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9d16(%rip), %rsi      # 0xda64
callq 0x21a0
cmpl $0x0, %eax
jne 0x3d68
leaq 0x9429(%rip), %rdi      # 0xd188
movb $0x0, %al
callq 0x20f0
jmp 0x3d85
leaq 0x942e(%rip), %rdi      # 0xd19d
movb $0x0, %al
callq 0x20f0
movl 0xe440(%rip), %eax      # 0x121bc
addl $0x1, %eax
movl %eax, 0xe437(%rip)      # 0x121bc
movq -0x8(%rbp), %rdi
callq 0x6c60
movl 0xe42c(%rip), %esi      # 0x121c0
addl $0x1, %esi
movl %esi, 0xe423(%rip)      # 0x121c0
leaq 0x938a(%rip), %rdi      # 0xd12e
movb $0x0, %al
callq 0x20f0
leaq 0x9cd2(%rip), %rdi      # 0xda84
movb $0x0, %al
callq 0x20f0
leaq 0x9cee(%rip), %rdi      # 0xdaae
movl $0x1, %esi
callq 0x6ed0
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x1, (%rax)
jne 0x3e00
movq -0x8(%rbp), %rdi
addq $0x4, %rdi
leaq 0x9cd2(%rip), %rsi      # 0xdab8
callq 0x21a0
cmpl $0x0, %eax
jne 0x3e00
leaq 0x9391(%rip), %rdi      # 0xd188
movb $0x0, %al
callq 0x20f0
jmp 0x3e1d
leaq 0x9396(%rip), %rdi      # 0xd19d
movb $0x0, %al
callq 0x20f0
movl 0xe3a8(%rip), %eax      # 0x121bc
addl $0x1, %eax
movl %eax, 0xe39f(%rip)      # 0x121bc
movq -0x8(%rbp), %rdi
callq 0x6c60
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)