git.ucc.asn.au
/
tpg
/
acess2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge branch 'master' of github.com:thepowersgang/acess2
[tpg/acess2.git]
/
Usermode
/
Libraries
/
liburi.so_src
/
main.c
diff --git
a/Usermode/Libraries/liburi.so_src/main.c
b/Usermode/Libraries/liburi.so_src/main.c
index
e8f8dea
..
a9f2e17
100644
(file)
--- a/
Usermode/Libraries/liburi.so_src/main.c
+++ b/
Usermode/Libraries/liburi.so_src/main.c
@@
-63,7
+63,7
@@
tURI *URI_Parse(const char *String)
{
int hostlen, portlen, pathlen;
tmp += 3; // Eat '://'
- ret = malloc(sizeof(tURI) +
strlen(String) - 2
);
+ ret = malloc(sizeof(tURI) +
protolen + 1 + strlen(tmp) + 1
);
ret->Proto = (char*)ret + sizeof(tURI);
memcpy(ret->Proto, String, protolen);
@@
-140,14
+140,8
@@
tURI *URI_Parse(const char *String)
else
ret->Path = ret->Host + hostlen + 1;
- tmp ++;
pathlen = 0;
- while(*tmp)
- {
- ret->Path[pathlen] = *tmp;
- tmp ++;
- pathlen ++;
- }
+ strcpy(ret->Path, tmp);
return ret;
}
UCC
git Repository :: git.ucc.asn.au