diff options
author | Juha Heinanen <jh@tutpro.com> | 2015-06-25 22:10:24 +0300 |
---|---|---|
committer | Juha Heinanen <jh@tutpro.com> | 2015-06-25 22:10:24 +0300 |
commit | 7ea02318a1c15ad37e118784fd22695b9671dce9 (patch) | |
tree | 26e1fe38dda78ab2da055546e2635d50153c600f /src/ua.c | |
parent | 26d7041d297e98d9b4fb9f45c868bbb7a31c6582 (diff) |
src/ua: skip initial white space from user given uri
Diffstat (limited to 'src/ua.c')
-rw-r--r-- | src/ua.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -7,6 +7,7 @@ #include <re.h> #include <baresip.h> #include "core.h" +#include <ctype.h> /** Magic number */ @@ -606,6 +607,9 @@ static int uri_complete(struct ua *ua, struct mbuf *buf, const char *uri) size_t len; int err = 0; + /* Skip initial whitespace */ + while (isspace(*uri)) uri++; + len = str_len(uri); /* Append sip: scheme if missing */ |