Use libglnx

Starting down the path of not using libgsystem.  The main win here
will be code sharing between ostree/rpm-ostree as well as going down
the path of not using GFile * for local files.
This commit is contained in:
Colin Walters committed 2015-02-22 21:02:27 -05:00
1 parent ef53e0100b
commit 965a304a17
13 files changed
+31 -10

No files matched your search

+2 -1
View File
@@ -31,6 +31,7 @@
#include "ostree-chain-input-stream.h"
#include "otutil.h"
#include "libgsystem.h"
#include "libglnx.h"
#define ALIGN_VALUE(this, boundary) \
(( ((unsigned long)(this)) + (((unsigned long)(boundary)) -1)) & (~(((unsigned long)(boundary))-1)))
@@ -209,7 +210,7 @@ file_header_new (GFileInfo *file_info,
guint32 mode;
const char *symlink_target;
GVariant *ret;
gs_unref_variant GVariant *tmp_xattrs = NULL;
g_autoptr(GVariant) tmp_xattrs = NULL;
uid = g_file_info_get_attribute_uint32 (file_info, "unix::uid");
gid = g_file_info_get_attribute_uint32 (file_info, "unix::gid");
+1 -1
View File
@@ -133,7 +133,7 @@ ot_util_variant_map (GFile *src,
GError **error)
{
gboolean ret = FALSE;
gs_unref_variant GVariant *ret_variant = NULL;
g_autoptr(GVariant) ret_variant = NULL;
GMappedFile *mfile = NULL;
mfile = gs_file_map_noatime (src, NULL, error);
+1
View File
@@ -26,6 +26,7 @@
#include <libgsystem.h>
#include <string.h> /* Yeah...let's just do that here. */
#include <gsystem-local-alloc.h>
#include <libglnx.h>
#define ot_gobject_refz(o) (o ? g_object_ref (o) : o)
+1 -1
View File
@@ -61,7 +61,7 @@ ot_admin_require_booted_deployment_or_osname (OstreeSysroot *sysroot,
char *
ot_admin_checksum_version (GVariant *checksum)
{
gs_unref_variant GVariant *metadata = NULL;
g_autoptr(GVariant) metadata = NULL;
const char *ret = NULL;
metadata = g_variant_get_child_value (checksum, 0);
+3 -1
View File
@@ -27,6 +27,8 @@
#include <stdlib.h>
#include <string.h>
#include <libglnx.h>
#include "ostree.h"
#include "ot-main.h"
#include "otutil.h"
@@ -230,7 +232,7 @@ ostree_option_context_parse (GOptionContext *context,
GCancellable *cancellable,
GError **error)
{
gs_unref_object OstreeRepo *repo = NULL;
glnx_unref_object OstreeRepo *repo = NULL;
gboolean success = FALSE;
/* Entries are listed in --help output in the order added. We add the