core: CHANGE CHECKSUM ALGORITHM, port checksum API to GFile
This commit originally was to port ostree_stat_and_checksum_file() to GFile*, but I noticed that the checksum code was reading data in host endianness. Fix that while we're here. This invalidates all existing repositories.
This commit is contained in:
1 parent
2c2b9c0e00
commit
b8cef545d1
5 files changed
+64
-86
No files matched your search
@@ -92,6 +92,8 @@ typedef enum {
|
||||
gboolean ostree_validate_checksum_string (const char *sha256,
|
||||
GError **error);
|
||||
|
||||
void ostree_checksum_update_stat (GChecksum *checksum, guint32 uid, guint32 gid, guint32 mode);
|
||||
|
||||
char *ostree_get_relative_object_path (const char *checksum,
|
||||
OstreeObjectType type,
|
||||
gboolean archive);
|
||||
@@ -107,11 +109,11 @@ gboolean ostree_parse_metadata_file (GFile *file,
|
||||
GVariant **out_variant,
|
||||
GError **error);
|
||||
|
||||
gboolean ostree_stat_and_checksum_file (int dirfd, const char *path,
|
||||
OstreeObjectType type,
|
||||
GChecksum **out_checksum,
|
||||
struct stat *out_stbuf,
|
||||
GError **error);
|
||||
gboolean ostree_checksum_file (GFile *f,
|
||||
OstreeObjectType type,
|
||||
GChecksum **out_checksum,
|
||||
GCancellable *cancellable,
|
||||
GError **error);
|
||||
|
||||
gboolean ostree_get_directory_metadata (GFile *dir,
|
||||
GVariant **out_metadata,
|
||||
@@ -154,7 +156,5 @@ gboolean ostree_unpack_object (const char *path,
|
||||
GChecksum **out_checksum,
|
||||
GError **error);
|
||||
|
||||
void ostree_checksum_update_stat (GChecksum *checksum, guint32 uid, guint32 gid, guint32 mode);
|
||||
|
||||
|
||||
#endif /* _OSTREE_REPO */
|
||||
Reference in new issue
Block a user