// File: /workspace/github_c_makefile_star2_O0/icebert[P]pblat/lib/net.c
// Function: netLineFileMayOpen
struct lineFile *netLineFileMayOpen(char *url)
/* Return a lineFile attached to url. http skips header.
 * Supports some compression formats.  Prints warning message, but
 * does not abort, just returning NULL if there's a problem. */
{
int sd = netUrlOpen(url);
if (sd < 0)
    {
    warn("Couldn't open %s", url);
    return NULL;
    }
else
    {
    struct lineFile *lf = NULL;
    char *newUrl = NULL;
    int newSd = 0;
    if (startsWith("http://",url) || startsWith("https://",url))
	{  
	if (!netSkipHttpHeaderLinesHandlingRedirect(sd, url, &newSd, &newUrl))
	    {
	    return NULL;
	    }
	if (newUrl != NULL)
	    {
    	    /*  Update sd with newSd, replace it with newUrl, etc. */
	    sd = newSd;
	    url = newUrl;
	    }
	}
    char *urlDecoded = cloneString(url);
    cgiDecode(url, urlDecoded, strlen(url));
    boolean isCompressed =
	(endsWith(urlDecoded,".gz") ||
   	 endsWith(urlDecoded,".Z")  ||
	 endsWith(urlDecoded,".bz2"));
    freeMem(urlDecoded);
    if (isCompressed)
	{
	lf = lineFileDecompressFd(url, TRUE, sd);
           /* url needed only for compress type determination */
	}
    else
	{
	lf = lineFileAttach(url, TRUE, sd);
	}
    if (newUrl) 
	freeMem(newUrl); 
    return lf;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x442f0
movl %eax, -0x14(%rbp)
cmpl $0x0, -0x14(%rbp)
jge 0x44efd
movq -0x10(%rbp), %rsi
leaq 0x9734f(%rip), %rdi     # 0xdc238
movb $0x0, %al
callq 0x358e0
movq $0x0, -0x8(%rbp)
jmp 0x4505f
movq $0x0, -0x20(%rbp)
movq $0x0, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
movq -0x10(%rbp), %rsi
leaq 0x96541(%rip), %rdi     # 0xdb460
callq 0x2d3d0
cmpl $0x0, %eax
jne 0x44f3e
movq -0x10(%rbp), %rsi
leaq 0x96534(%rip), %rdi     # 0xdb468
callq 0x2d3d0
cmpl $0x0, %eax
je 0x44f7b
movl -0x14(%rbp), %edi
movq -0x10(%rbp), %rsi
leaq -0x2c(%rbp), %rdx
leaq -0x28(%rbp), %rcx
callq 0x44d30
cmpl $0x0, %eax
jne 0x44f64
movq $0x0, -0x8(%rbp)
jmp 0x4505f
cmpq $0x0, -0x28(%rbp)
je 0x44f79
movl -0x2c(%rbp), %eax
movl %eax, -0x14(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x10(%rbp)
jmp 0x44f7b
movq -0x10(%rbp), %rdi
callq 0x2a450
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x50(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x10(%rbp), %rdi
callq 0x62c0
movq -0x50(%rbp), %rdi
movq -0x48(%rbp), %rsi
movl %eax, %edx
callq 0x63670
movq -0x38(%rbp), %rdi
leaq 0x9d592(%rip), %rsi     # 0xe254d
callq 0x2d9a0
movl %eax, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x3d(%rbp)
jne 0x45001
movq -0x38(%rbp), %rdi
leaq 0x92fd2(%rip), %rsi     # 0xd7fa9
callq 0x2d9a0
movl %eax, %ecx
movb $0x1, %al
cmpl $0x0, %ecx
movb %al, -0x3d(%rbp)
jne 0x45001
movq -0x38(%rbp), %rdi
leaq 0x92fb9(%rip), %rsi     # 0xd7fac
callq 0x2d9a0
cmpl $0x0, %eax
setne %al
movb %al, -0x3d(%rbp)
movb -0x3d(%rbp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, -0x3c(%rbp)
movq -0x38(%rbp), %rdi
callq 0x40d40
cmpl $0x0, -0x3c(%rbp)
je 0x45032
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %edx
movl $0x1, %esi
callq 0x3ac70
movq %rax, -0x20(%rbp)
jmp 0x45047
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %edx
movl $0x1, %esi
callq 0x3abf0
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x45057
movq -0x28(%rbp), %rdi
callq 0x40d40
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax)