[gnome-online-accounts/wip/rishi/warnings: 3/4] utils: Domain names may not have a dot; usernames shouldn't be empty
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-online-accounts/wip/rishi/warnings: 3/4] utils: Domain names may not have a dot; usernames shouldn't be empty
- Date: Fri, 3 Nov 2017 19:34:05 +0000 (UTC)
commit 00130cd0e3d851da883674df70d3673fd9d76956
Author: Debarshi Ray <debarshir gnome org>
Date: Fri Nov 3 19:54:59 2017 +0100
utils: Domain names may not have a dot; usernames shouldn't be empty
https://bugzilla.gnome.org/show_bug.cgi?id=789187
src/goabackend/goautils.c | 6 +-----
1 files changed, 1 insertions(+), 5 deletions(-)
---
diff --git a/src/goabackend/goautils.c b/src/goabackend/goautils.c
index 5029e07..87d2ea1 100644
--- a/src/goabackend/goautils.c
+++ b/src/goabackend/goautils.c
@@ -839,11 +839,7 @@ goa_utils_parse_email_address (const gchar *email, gchar **out_username, gchar *
return FALSE;
at = strchr (email, '@');
- if (at == NULL || *(at + 1) == '\0')
- return FALSE;
-
- dot = strchr (at + 1, '.');
- if (dot == NULL || *(dot + 1) == '\0')
+ if (at == NULL || at == email || *(at + 1) == '\0')
return FALSE;
if (out_username != NULL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]