general: Add missing `static` modifier to various local methods

The compiler warning flag which was supposed to warn about this was not
being included in the CFLAGS for these targets. That will be fixed in an
upcoming commit.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
tingping/wmclass
Philip Withnall 2017-07-06 14:38:10 +01:00
parent a80a1b9bb2
commit 548f60ebc0
13 changed files with 23 additions and 23 deletions

View File

@ -199,7 +199,7 @@ commit_filter (OstreeRepo *repo,
return OSTREE_REPO_COMMIT_FILTER_ALLOW;
}
gboolean
static gboolean
add_file_to_mtree (GFile *file,
const char *name,
OstreeRepo *repo,

View File

@ -54,7 +54,7 @@ looks_like_branch (const char *branch)
return TRUE;
}
SoupSession *
static SoupSession *
get_soup_session (void)
{
static SoupSession *soup_session = NULL;

View File

@ -137,7 +137,7 @@ message_handler (const gchar *log_domain,
g_printerr ("%s: %s\n", g_get_prgname (), message);
}
GOptionContext *
static GOptionContext *
flatpak_option_context_new_with_commands (FlatpakCommand *commands)
{
GOptionContext *context;
@ -173,7 +173,7 @@ flatpak_option_context_new_with_commands (FlatpakCommand *commands)
return context;
}
int
static int
flatpak_usage (FlatpakCommand *commands,
gboolean is_error)
{
@ -292,7 +292,7 @@ usage_error (GOptionContext *context, const char *message, GError **error)
return FALSE;
}
FlatpakCommand *
static FlatpakCommand *
extract_command (int *argc,
char **argv,
const char **command_name_out)
@ -340,7 +340,7 @@ extract_command (int *argc,
}
int
static int
flatpak_run (int argc,
char **argv,
GError **res_error)

View File

@ -192,7 +192,7 @@ flatpak_transaction_free (FlatpakTransaction *self)
g_free (self);
}
gboolean
static gboolean
flatpak_transaction_contains_ref (FlatpakTransaction *self,
const char *ref)
{
@ -245,7 +245,7 @@ kind_to_str (FlatpakTransactionOpKind kind)
return "unknown";
}
FlatpakTransactionOp *
static FlatpakTransactionOp *
flatpak_transaction_add_op (FlatpakTransaction *self,
const char *remote,
const char *ref,

View File

@ -569,7 +569,7 @@ builder_context_set_bundle_sources (BuilderContext *self,
static char *rofiles_unmount_path = NULL;
void
static void
rofiles_umount_handler (int signum)
{
char *argv[] = { "fusermount", "-u", NULL,

View File

@ -106,7 +106,7 @@ builder_git_get_current_commit (const char *repo_location,
return git_get_current_commit (mirror_dir, branch, ensure_commit, context, error);
}
char *
static char *
make_absolute (const char *orig_parent, const char *orig_relpath, GError **error)
{
g_autofree char *parent = g_strdup (orig_parent);

View File

@ -135,7 +135,7 @@ message_handler (const gchar *log_domain,
g_printerr ("%s: %s\n", g_get_prgname (), message);
}
int
static int
usage (GOptionContext *context, const char *message)
{
g_autofree gchar *help = g_option_context_get_help (context, TRUE, NULL);

View File

@ -1353,7 +1353,7 @@ builder_manifest_checksum (BuilderManifest *self,
builder_options_checksum (self->build_options, cache, context);
}
void
static void
builder_manifest_checksum_for_cleanup (BuilderManifest *self,
BuilderCache *cache,
BuilderContext *context)
@ -1378,7 +1378,7 @@ builder_manifest_checksum_for_cleanup (BuilderManifest *self,
}
}
void
static void
builder_manifest_checksum_for_finish (BuilderManifest *self,
BuilderCache *cache,
BuilderContext *context)
@ -1403,7 +1403,7 @@ builder_manifest_checksum_for_finish (BuilderManifest *self,
}
}
void
static void
builder_manifest_checksum_for_bundle_sources (BuilderManifest *self,
BuilderCache *cache,
BuilderContext *context)
@ -1412,7 +1412,7 @@ builder_manifest_checksum_for_bundle_sources (BuilderManifest *self,
builder_cache_checksum_boolean (cache, builder_context_get_bundle_sources (context));
}
void
static void
builder_manifest_checksum_for_platform (BuilderManifest *self,
BuilderCache *cache,
BuilderContext *context)

View File

@ -72,13 +72,13 @@ typedef enum {
ZIP
} BuilderArchiveType;
gboolean
static gboolean
is_tar (BuilderArchiveType type)
{
return (type >= TAR) && (type <= TAR_XZ);
}
const char *
static const char *
tar_decompress_flag (BuilderArchiveType type)
{
switch (type)
@ -389,7 +389,7 @@ unrpm (GFile *dir,
return res;
}
BuilderArchiveType
static BuilderArchiveType
get_type (GFile *archivefile)
{
g_autofree char *base_name = NULL;

View File

@ -63,7 +63,7 @@ builder_uri_to_filename (const char *uri)
return g_string_free (s, FALSE);
}
const char *
static const char *
inplace_basename (const char *path)
{
const char *last_slash;

View File

@ -401,7 +401,7 @@ flatpak_proxy_client_init (FlatpakProxyClient *client)
client->unique_id_policy = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, NULL);
}
FlatpakProxyClient *
static FlatpakProxyClient *
flatpak_proxy_client_new (FlatpakProxy *proxy, GSocketConnection *connection)
{
FlatpakProxyClient *client;

View File

@ -573,7 +573,7 @@ xdp_inode_rename_child (XdpInode *dir,
}
/* NULL if removed */
char *
static char *
xdp_inode_get_filename (XdpInode *inode)
{
AUTOLOCK (inodes);
@ -1043,7 +1043,7 @@ xdp_fuse_lookup (fuse_req_t req,
fuse_reply_entry (req, &e);
}
void
static void
xdp_fuse_forget (fuse_req_t req, fuse_ino_t ino, unsigned long nlookup)
{
g_autoptr(XdpInode) inode = NULL;

View File

@ -274,7 +274,7 @@ portal_delete (GDBusMethodInvocation *invocation,
g_dbus_method_invocation_return_value (invocation, g_variant_new ("()"));
}
char *
static char *
do_create_doc (struct stat *parent_st_buf, const char *path, gboolean reuse_existing, gboolean persistent)
{
g_autoptr(GVariant) data = NULL;