X-Git-Url: https://wimlib.net/git/?p=wimlib;a=blobdiff_plain;f=src%2Fmount_image.c;h=b53dfb5c1196bdb6ba7674b7fb2cf1cdbb5ec0ab;hp=f9d4c4001045a4880485fe211b1a1fd2df8808e9;hb=32614c9f026be20f0336df3053b91090dc53297f;hpb=9521348eebfb0e91c9c9567f58fe6a7adca49f06 diff --git a/src/mount_image.c b/src/mount_image.c index f9d4c400..b53dfb5c 100644 --- a/src/mount_image.c +++ b/src/mount_image.c @@ -379,16 +379,16 @@ wim_pathname_to_stream(const struct wimfs_context *ctx, const char *path, struct wim_dentry *dentry; struct wim_lookup_table_entry *lte; u16 stream_idx; - const tchar *stream_name = NULL; + const char *stream_name = NULL; struct wim_inode *inode; - tchar *p = NULL; + char *p = NULL; lookup_flags |= ctx->default_lookup_flags; if (lookup_flags & LOOKUP_FLAG_ADS_OK) { stream_name = path_stream_name(path); if (stream_name) { - p = (tchar*)stream_name - 1; + p = (char *)stream_name - 1; *p = T('\0'); } } @@ -2416,7 +2416,8 @@ do_unmount_commit(const char *dir, int unmount_flags, ret = do_unmount(dir); if (progfunc) { /* Terminate the progress thread. */ - mq_send(mq, NULL, 0, 1); + char empty[0]; + mq_send(mq, empty, 0, 1); pthread_join(commit_progress_tid, NULL); } out_delete_mq: @@ -2477,7 +2478,9 @@ wimlib_unmount_image_with_progress(const char *dir, int unmount_flags, int mount_flags; int ret; - wimlib_global_init(WIMLIB_INIT_FLAG_ASSUME_UTF8); + ret = wimlib_global_init(WIMLIB_INIT_FLAG_ASSUME_UTF8); + if (ret) + return ret; if (unmount_flags & ~(WIMLIB_UNMOUNT_FLAG_CHECK_INTEGRITY | WIMLIB_UNMOUNT_FLAG_COMMIT |