// File: DoubleString[P]RtConverter/src/Rtklib/stream.cpp
// Function: bamboo::decodeftppath(char const*, char*, char*, char*, char*, int*)
static void decodeftppath(const char *path, char *addr, char *file, char *user,
		char *passwd, int *topts)
	{
		char buff[MAXSTRPATH], *p, *q;

		tracet(4, "decodeftpath: path=%s\n", path);

		if (user) *user = '\0';
		if (passwd) *passwd = '\0';
		if (topts) {
			topts[0] = 0;    /* time offset in path (s) */
			topts[1] = 3600; /* download interval (s) */
			topts[2] = 0;    /* download time offset (s) */
			topts[3] = 0;    /* retry interval (s) (0: no retry) */
		}
		strcpy(buff, path);

		if ((p = strchr(buff, '/'))) {
			if ((q = strstr(p + 1, "::"))) {
				*q = '\0';
				if (topts) sscanf(q + 2, "T=%d,%d,%d,%d", topts, topts + 1, topts + 2, topts + 3);
			}
			strcpy(file, p + 1);
			*p = '\0';
		}
		else file[0] = '\0';

		if ((p = strrchr(buff, '@'))) {
			*p++ = '\0';
			if ((q = strchr(buff, ':'))) {
				*q = '\0'; if (passwd) strcpy(passwd, q + 1);
			}
			*q = '\0'; if (user) strcpy(user, buff);
		}
		else p = buff;

		strcpy(addr, p);
	}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x440, %rsp            # imm = 0x440
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq %r8, -0x28(%rbp)
movq %r9, -0x30(%rbp)
movq -0x8(%rbp), %rdx
movl $0x4, %edi
leaq 0x24914(%rip), %rsi     # 0xc9277
movb $0x0, %al
callq 0x95890
cmpq $0x0, -0x20(%rbp)
je 0xa4978
movq -0x20(%rbp), %rax
movb $0x0, (%rax)
cmpq $0x0, -0x28(%rbp)
je 0xa4986
movq -0x28(%rbp), %rax
movb $0x0, (%rax)
cmpq $0x0, -0x30(%rbp)
je 0xa49b8
movq -0x30(%rbp), %rax
movl $0x0, (%rax)
movq -0x30(%rbp), %rax
movl $0xe10, 0x4(%rax)       # imm = 0xE10
movq -0x30(%rbp), %rax
movl $0x0, 0x8(%rax)
movq -0x30(%rbp), %rax
movl $0x0, 0xc(%rax)
leaq -0x430(%rbp), %rdi
movq -0x8(%rbp), %rsi
callq 0x96f0
leaq -0x430(%rbp), %rdi
movl $0x2f, %esi
callq 0x9280
movq %rax, -0x438(%rbp)
cmpq $0x0, %rax
je 0xa4a76
movq -0x438(%rbp), %rdi
addq $0x1, %rdi
leaq 0x243a8(%rip), %rsi     # 0xc8da4
callq 0x91b0
movq %rax, -0x440(%rbp)
cmpq $0x0, %rax
je 0xa4a56
movq -0x440(%rbp), %rax
movb $0x0, (%rax)
cmpq $0x0, -0x30(%rbp)
je 0xa4a54
movq -0x440(%rbp), %rdi
addq $0x2, %rdi
movq -0x30(%rbp), %rdx
movq -0x30(%rbp), %rcx
addq $0x4, %rcx
movq -0x30(%rbp), %r8
addq $0x8, %r8
movq -0x30(%rbp), %r9
addq $0xc, %r9
leaq 0x24841(%rip), %rsi     # 0xc928e
movb $0x0, %al
callq 0x9750
jmp 0xa4a56
movq -0x18(%rbp), %rdi
movq -0x438(%rbp), %rsi
addq $0x1, %rsi
callq 0x96f0
movq -0x438(%rbp), %rax
movb $0x0, (%rax)
jmp 0xa4a7d
movq -0x18(%rbp), %rax
movb $0x0, (%rax)
leaq -0x430(%rbp), %rdi
movl $0x40, %esi
callq 0x9820
movq %rax, -0x438(%rbp)
cmpq $0x0, %rax
je 0xa4b1f
movq -0x438(%rbp), %rax
movq %rax, %rcx
addq $0x1, %rcx
movq %rcx, -0x438(%rbp)
movb $0x0, (%rax)
leaq -0x430(%rbp), %rdi
movl $0x3a, %esi
callq 0x9280
movq %rax, -0x440(%rbp)
cmpq $0x0, %rax
je 0xa4afc
movq -0x440(%rbp), %rax
movb $0x0, (%rax)
cmpq $0x0, -0x28(%rbp)
je 0xa4afa
movq -0x28(%rbp), %rdi
movq -0x440(%rbp), %rsi
addq $0x1, %rsi
callq 0x96f0
jmp 0xa4afc
movq -0x440(%rbp), %rax
movb $0x0, (%rax)
cmpq $0x0, -0x20(%rbp)
je 0xa4b1d
movq -0x20(%rbp), %rdi
leaq -0x430(%rbp), %rsi
callq 0x96f0
jmp 0xa4b2d
leaq -0x430(%rbp), %rax
movq %rax, -0x438(%rbp)
movq -0x10(%rbp), %rdi
movq -0x438(%rbp), %rsi
callq 0x96f0
addq $0x440, %rsp            # imm = 0x440
popq %rbp
retq
nopw %cs:(%rax,%rax)