Lines 198-204
Link Here
|
198 |
return err; |
198 |
return err; |
199 |
} |
199 |
} |
200 |
|
200 |
|
201 |
static char *get_name(char *name, char *p) |
201 |
char *get_name(char *name, char *p) |
202 |
{ |
202 |
{ |
203 |
while (isspace(*p)) |
203 |
while (isspace(*p)) |
204 |
p++; |
204 |
p++; |
Lines 206-221
Link Here
|
206 |
if (isspace(*p)) |
206 |
if (isspace(*p)) |
207 |
break; |
207 |
break; |
208 |
if (*p == ':') { /* could be an alias */ |
208 |
if (*p == ':') { /* could be an alias */ |
209 |
char *dot = p, *dotname = name; |
209 |
char *dot = p++; |
210 |
*name++ = *p++; |
210 |
while (*p && isdigit(*p)) p++; |
211 |
while (isdigit(*p)) |
211 |
if (*p == ':') { |
212 |
*name++ = *p++; |
212 |
/* Yes it is, backup and copy it. */ |
213 |
if (*p != ':') { /* it wasn't, backup */ |
213 |
p = dot; |
214 |
p = dot; |
214 |
*name++ = *p++; |
215 |
name = dotname; |
215 |
while (*p && isdigit(*p)) { |
|
|
216 |
*name++ = *p++; |
217 |
} |
218 |
} else { |
219 |
/* No, it isn't */ |
220 |
p = dot; |
216 |
} |
221 |
} |
217 |
if (*p == '\0') |
|
|
218 |
return NULL; |
219 |
p++; |
222 |
p++; |
220 |
break; |
223 |
break; |
221 |
} |
224 |
} |