Skip to content

Commit 05551ca

Browse files
committed
Remove now unnecessary gitno_unescape
1 parent 60e7848 commit 05551ca

File tree

2 files changed

+0
-20
lines changed

2 files changed

+0
-20
lines changed

src/netops.c

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -206,24 +206,6 @@ void gitno_connection_data_free_ptrs(gitno_connection_data *d)
206206
git__free(d->pass); d->pass = NULL;
207207
}
208208

209-
#define hex2c(c) ((c | 32) % 39 - 9)
210-
char* gitno_unescape(char *str)
211-
{
212-
int x, y;
213-
int len = (int)strlen(str);
214-
215-
for (x=y=0; str[y]; ++x, ++y) {
216-
if ((str[x] = str[y]) == '%') {
217-
if (y < len-2 && isxdigit(str[y+1]) && isxdigit(str[y+2])) {
218-
str[x] = (hex2c(str[y+1]) << 4) + hex2c(str[y+2]);
219-
y += 2;
220-
}
221-
}
222-
}
223-
str[x] = '\0';
224-
return str;
225-
}
226-
227209
int gitno_extract_url_parts(
228210
char **host_out,
229211
char **port_out,

src/netops.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,4 @@ int gitno_extract_url_parts(
9696
const char *url,
9797
const char *default_port);
9898

99-
char* gitno_unescape(char *str);
100-
10199
#endif

0 commit comments

Comments
 (0)