Switch to #pragma once for headers

It's just less tedious, and we're GCC/LLVM specific anyways.
This commit is contained in:
Colin Walters 2013-07-09 18:53:22 -04:00
parent 7f48c77204
commit 5ad0671cd2
36 changed files with 39 additions and 106 deletions

View File

@ -19,8 +19,7 @@
*
*/
#ifndef __OSTREE_CHAIN_INPUT_STREAM_H__
#define __OSTREE_CHAIN_INPUT_STREAM_H__
#pragma once
#include <gio/gio.h>
@ -64,4 +63,3 @@ OstreeChainInputStream * ostree_chain_input_stream_new (GPtrArray *stre
G_END_DECLS
#endif /* __OSTREE_CHAIN_INPUT_STREAM_H__ */

View File

@ -19,8 +19,7 @@
*
*/
#ifndef __OSTREE_CHECKSUM_INPUT_STREAM_H__
#define __OSTREE_CHECKSUM_INPUT_STREAM_H__
#pragma once
#include <gio/gio.h>
@ -65,4 +64,3 @@ OstreeChecksumInputStream * ostree_checksum_input_stream_new (GInputStr
G_END_DECLS
#endif /* __OSTREE_CHECKSUM_INPUT_STREAM_H__ */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_CORE
#define _OSTREE_CORE
#pragma once
#include <otutil.h>
@ -308,4 +307,5 @@ gboolean ostree_validate_structureof_dirtree (GVariant *index,
gboolean ostree_validate_structureof_dirmeta (GVariant *index,
GError **error);
#endif /* _OSTREE_REPO */
G_END_DECLS

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_DIFF
#define _OSTREE_DIFF
#pragma once
#include "ostree-core.h"
#include "ostree-types.h"
@ -62,4 +61,3 @@ void ostree_diff_print (GFile *a,
G_END_DECLS
#endif /* _OSTREE_REPO */

View File

@ -20,8 +20,7 @@
* Author: Alexander Larsson <alexl@redhat.com>
*/
#ifndef __OSTREE_LIBARCHIVE_INPUT_STREAM_H__
#define __OSTREE_LIBARCHIVE_INPUT_STREAM_H__
#pragma once
#include <gio/gio.h>
@ -65,4 +64,3 @@ GInputStream * ostree_libarchive_input_stream_new (struct archive *a);
G_END_DECLS
#endif /* __OSTREE_LIBARCHIVE_INPUT_STREAM_H__ */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_MUTABLE_TREE
#define _OSTREE_MUTABLE_TREE
#pragma once
#include "ostree-types.h"
@ -94,4 +93,3 @@ GHashTable * ostree_mutable_tree_get_files (OstreeMutableTree *self);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_REPO_FILE_ENUMERATOR
#define _OSTREE_REPO_FILE_ENUMERATOR
#pragma once
#include "ostree-repo-file.h"
@ -54,4 +53,3 @@ GFileEnumerator * _ostree_repo_file_enumerator_new (OstreeRepoFile *d
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_REPO_FILE
#define _OSTREE_REPO_FILE
#pragma once
#include "ostree-types.h"
@ -96,4 +95,3 @@ GVariant *ostree_repo_file_tree_get_metadata (OstreeRepoFile *self);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_REPO
#define _OSTREE_REPO
#pragma once
#include "ostree-core.h"
#include "ostree-types.h"
@ -320,4 +319,3 @@ gboolean ostree_repo_list_objects (OstreeRepo *self,
G_END_DECLS
#endif /* _OSTREE_REPO */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_TRAVERSE
#define _OSTREE_TRAVERSE
#pragma once
#include "ostree-core.h"
#include "ostree-types.h"
@ -45,4 +44,3 @@ gboolean ostree_traverse_commit (OstreeRepo *repo,
G_END_DECLS
#endif /* _OSTREE_REPO */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef _OSTREE_TYPES
#define _OSTREE_TYPES
#pragma once
#include <gio/gio.h>
@ -36,4 +35,3 @@ typedef struct OstreeRepoFile OstreeRepoFile;
G_END_DECLS
#endif

View File

@ -20,7 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_H__
#pragma once
#include <ostree-checksum-input-stream.h>
#include <ostree-chain-input-stream.h>
@ -30,5 +30,3 @@
#include <ostree-repo-file.h>
#include <ostree-traverse.h>
#include <ostree-diff.h>
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_CHECKSUM_UTILS_H__
#define __OSTREE_CHECKSUM_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -65,5 +64,3 @@ guchar * ot_gio_checksum_stream_finish (GInputStream *in,
GError **error);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_GIO_UTILS_H__
#define __OSTREE_GIO_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -81,4 +80,3 @@ gboolean ot_gfile_atomic_symlink_swap (GFile *path,
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_KEYFILE_UTILS_H__
#define __OSTREE_KEYFILE_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -46,4 +45,3 @@ ot_keyfile_get_value_with_default (GKeyFile *keyfile,
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_OPT_UTILS_H__
#define __OSTREE_OPT_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -31,4 +30,3 @@ void ot_util_usage_error (GOptionContext *context, const char *message, GError *
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_SPAWN_UTILS_H__
#define __OSTREE_SPAWN_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -33,4 +32,3 @@ GThreadPool * ot_thread_pool_new_nproc (GFunc func,
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_UNIX_UTILS_H__
#define __OSTREE_UNIX_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -51,4 +50,3 @@ void ot_util_set_error_from_errno (GError **error, gint saved_errno);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_VARIANT_UTILS_H__
#define __OSTREE_VARIANT_UTILS_H__
#pragma once
#include <gio/gio.h>
@ -56,4 +55,3 @@ GInputStream *ot_variant_read (GVariant *variant);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_WAITABLE_QUEUE_H__
#define __OSTREE_WAITABLE_QUEUE_H__
#pragma once
#include <gio/gio.h>
@ -44,4 +43,3 @@ void ot_waitable_queue_unref (OtWaitableQueue *queue);
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_UTIL_H__
#define __OSTREE_UTIL_H__
#pragma once
#include <gio/gio.h>
#include <libgsystem.h>
@ -48,4 +47,3 @@
void ot_ptrarray_add_many (GPtrArray *a, ...) G_GNUC_NULL_TERMINATED;
#endif

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef _OSTREE_CURL_FETCHER
#define _OSTREE_CURL_FETCHER
#pragma once
#include <gio/gio.h>
@ -56,4 +55,3 @@ GFile *ostree_curl_fetcher_request_uri_finish (OstreeCurlFetcher *self,
G_END_DECLS
#endif

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef _OSTREE_FETCHER
#define _OSTREE_FETCHER
#pragma once
#define LIBSOUP_USE_UNSTABLE_REQUEST_API
#include <libsoup/soup.h>
@ -71,4 +70,3 @@ GFile *ostree_fetcher_request_uri_finish (OstreeFetcher *self,
G_END_DECLS
#endif

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_PRUNE_H__
#define __OT_PRUNE_H__
#pragma once
#include "ostree.h"
@ -42,4 +41,3 @@ gboolean ostree_prune (OstreeRepo *repo,
G_END_DECLS
#endif /* __OT_PRUNE_H__ */

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_PULL_H__
#define __OT_PULL_H__
#pragma once
#include "ostree.h"
@ -39,4 +38,3 @@ gboolean ostree_pull (OstreeRepo *repo,
G_END_DECLS
#endif /* __OT_PRUNE_H__ */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OT_ADMIN_BUILTINS__
#define __OT_ADMIN_BUILTINS__
#pragma once
#include <gio/gio.h>
@ -42,4 +41,3 @@ gboolean ot_admin_builtin_upgrade (int argc, char **argv, OtAdminBuiltinOpts *ad
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OT_ADMIN_DEPLOY__
#define __OT_ADMIN_DEPLOY_
#pragma once
#include <gio/gio.h>
#include "ot-deployment.h"
@ -48,4 +47,3 @@ gboolean ot_admin_deploy (GFile *sysroot,
G_END_DECLS
#endif

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OT_ADMIN_FUNCTIONS__
#define __OT_ADMIN_FUNCTIONS__
#pragma once
#include <gio/gio.h>
#include "ostree.h"
@ -120,4 +119,3 @@ GKeyFile *ot_origin_new_from_refspec (const char *refspec);
G_END_DECLS
#endif

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_BOOTLOADER_SYSLINUX_H__
#define __OT_BOOTLOADER_SYSLINUX_H__
#pragma once
#include "ot-bootloader.h"
@ -37,4 +36,3 @@ OtBootloaderSyslinux * ot_bootloader_syslinux_new (GFile *sysroot);
G_END_DECLS
#endif /* __OT_BOOTLOADER_SYSLINUX_H__ */

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_BOOTLOADER_H__
#define __OT_BOOTLOADER_H__
#pragma once
#include <gio/gio.h>
@ -56,4 +55,3 @@ gboolean ot_bootloader_write_config (OtBootloader *self,
G_END_DECLS
#endif /* __OT_BOOTLOADER_H__ */

View File

@ -20,8 +20,7 @@
* Author: Colin Walters <walters@verbum.org>
*/
#ifndef __OSTREE_BUILTINS__
#define __OSTREE_BUILTINS__
#pragma once
#include <gio/gio.h>
@ -50,4 +49,3 @@ gboolean ostree_builtin_trivial_httpd (int argc, char **argv, GFile *repo_path,
G_END_DECLS
#endif

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_CONFIG_PARSER_H__
#define __OT_CONFIG_PARSER_H__
#pragma once
#include <gio/gio.h>
@ -55,4 +54,3 @@ const char *ot_config_parser_get (OtConfigParser *self,
G_END_DECLS
#endif /* __OT_CONFIG_PARSER_H__ */

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_DEPLOYMENT_H__
#define __OT_DEPLOYMENT_H__
#pragma once
#include <gio/gio.h>
#include "ot-config-parser.h"
@ -63,4 +62,3 @@ OtDeployment *ot_deployment_clone (OtDeployment *self);
G_END_DECLS
#endif /* __OT_DEPLOYMENT_H__ */

View File

@ -20,6 +20,8 @@
* Author: Colin Walters <walters@verbum.org>
*/
#pragma once
#include <gio/gio.h>
typedef enum {

View File

@ -18,8 +18,7 @@
* Boston, MA 02111-1307, USA.
*/
#ifndef __OT_ORDERED_HASH_H__
#define __OT_ORDERED_HASH_H__
#pragma once
#include <gio/gio.h>
@ -43,4 +42,3 @@ void ot_ordered_hash_replace_key (OtOrderedHash *ohash,
G_END_DECLS
#endif /* __OT_ORDERED_HASH_H__ */

View File

@ -19,9 +19,7 @@
*
*/
#ifndef _OSTREE_MOUNT_UTIL_H
#define _OSTREE_MOUNT_UTIL_H
#pragma once
int perrorv (const char *format, ...) __attribute__ ((format (printf, 1, 2)));
#endif