lib/core: Add ostree_validate_remote_name() for remote names

There are a few places in the code where ad-hoc validation was being
performed. Might as well formalise it a bit more.

Signed-off-by: Philip Withnall <withnall@endlessm.com>

Closes: #948
Approved by: cgwalters
This commit is contained in:
Philip Withnall authored and Atomic Bot committed 2017-06-20 21:52:22 +00:00
1 parent fd50c97322
commit 20dc9454b3
6 files changed
+62 -6

No files matched your search

+3
View File
@@ -242,6 +242,9 @@ int ostree_cmp_checksum_bytes (const guchar *a, const guchar *b);
_OSTREE_PUBLIC
gboolean ostree_validate_rev (const char *rev, GError **error);
_OSTREE_PUBLIC
gboolean ostree_validate_remote_name (const char *remote_name, GError **error);
_OSTREE_PUBLIC
gboolean ostree_parse_refspec (const char *refspec,
char **out_remote,