[network-manager-fortisslvpn: 22/30] src: make valid_properties array const
- From: Thomas Haller <thaller src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-fortisslvpn: 22/30] src: make valid_properties array const
- Date: Mon, 19 Sep 2016 13:44:15 +0000 (UTC)
commit 386b253bf6bd31315f5e645f519d6870810f6f1b
Author: Thomas Haller <thaller redhat com>
Date: Fri Sep 16 16:32:37 2016 +0200
src: make valid_properties array const
src/nm-fortisslvpn-service.c | 14 +++++++-------
1 files changed, 7 insertions(+), 7 deletions(-)
---
diff --git a/src/nm-fortisslvpn-service.c b/src/nm-fortisslvpn-service.c
index e05805c..aacf2b8 100644
--- a/src/nm-fortisslvpn-service.c
+++ b/src/nm-fortisslvpn-service.c
@@ -78,25 +78,25 @@ typedef struct {
typedef struct {
const char *name;
GType type;
- gboolean required;
+ bool required:1;
} ValidProperty;
/*****************************************************************************/
-static ValidProperty valid_properties[] = {
+static const ValidProperty valid_properties[] = {
{ NM_FORTISSLVPN_KEY_GATEWAY, G_TYPE_STRING, TRUE },
{ NM_FORTISSLVPN_KEY_USER, G_TYPE_STRING, TRUE },
{ NM_FORTISSLVPN_KEY_CA, G_TYPE_STRING, FALSE },
{ NM_FORTISSLVPN_KEY_TRUSTED_CERT, G_TYPE_STRING, FALSE },
{ NM_FORTISSLVPN_KEY_CERT, G_TYPE_STRING, FALSE },
{ NM_FORTISSLVPN_KEY_KEY, G_TYPE_STRING, FALSE },
- { NM_FORTISSLVPN_KEY_PASSWORD"-flags", G_TYPE_UINT, FALSE },
- { NULL, G_TYPE_NONE, FALSE }
+ { NM_FORTISSLVPN_KEY_PASSWORD"-flags", G_TYPE_UINT, FALSE },
+ { NULL }
};
-static ValidProperty valid_secrets[] = {
+static const ValidProperty valid_secrets[] = {
{ NM_FORTISSLVPN_KEY_PASSWORD, G_TYPE_STRING, TRUE },
- { NULL, G_TYPE_NONE, FALSE }
+ { NULL }
};
/*****************************************************************************/
@@ -161,7 +161,7 @@ validate_ca (const char *ca)
}
typedef struct ValidateInfo {
- ValidProperty *table;
+ const ValidProperty *table;
GError **error;
gboolean have_items;
} ValidateInfo;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]