Navigation Menu

Skip to content

Commit

Permalink
[control] Make internal module state data static
Browse files Browse the repository at this point in the history
Global data is problematic in general and these values have accessor
functions anyway and thus there is no reason for extern visibility.

Signed-off-by: Simo Piiroinen <simo.piiroinen@jollamobile.com>
  • Loading branch information
spiiroin committed Sep 5, 2018
1 parent 4873888 commit a8b0b33
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/usb_moded-control.c
Expand Up @@ -62,21 +62,21 @@ bool control_get_connection_state (void);
*
* What was the last mode signaled over D-Bus.
*/
char *control_external_mode = NULL;
static char *control_external_mode = NULL;

/** The logical mode name
*
* Full set of valid modes can occur here
*/
char *control_internal_mode = NULL;
static char *control_internal_mode = NULL;

/** Connection status
*
* Access only via:
* - control_set_cable_state()
* - control_get_connection_state()
*/
cable_state_t control_cable_state = CABLE_STATE_UNKNOWN;
static cable_state_t control_cable_state = CABLE_STATE_UNKNOWN;

/* ========================================================================= *
* Functions
Expand Down

0 comments on commit a8b0b33

Please sign in to comment.