#include <string.h>
#include <locale.h>
-static int extract_wim_chunk_to_ntfs_attr(const void *buf, size_t len,
- u64 offset, void *arg)
+static int
+extract_wim_chunk_to_ntfs_attr(const void *buf, size_t len,
+ u64 offset, void *arg)
{
ntfs_attr *na = arg;
if (ntfs_attr_pwrite(na, offset, len, buf) == len) {
*
* Returns 0 on success, nonzero on failure.
*/
-static int write_ntfs_data_streams(ntfs_inode *ni, const struct wim_dentry *dentry,
- union wimlib_progress_info *progress_info)
+static int
+write_ntfs_data_streams(ntfs_inode *ni, const struct wim_dentry *dentry,
+ union wimlib_progress_info *progress_info)
{
int ret = 0;
unsigned stream_idx = 0;
static ntfs_inode *
dentry_open_parent_ni(const struct wim_dentry *dentry, ntfs_volume *vol)
{
- mbchar *p;
- const mbchar *dir_name;
+ char *p;
+ const char *dir_name;
ntfs_inode *dir_ni;
- mbchar orig;
+ char orig;
p = dentry->full_path + dentry->full_path_nbytes;
do {
return WIMLIB_ERR_NTFS_3G;
}
if (inode->i_security_id != -1 &&
- !(extract_flags & WIMLIB_EXTRACT_FLAG_NOACLS))
+ !(extract_flags & WIMLIB_EXTRACT_FLAG_NO_ACLS))
{
const char *desc;
const struct wim_security_data *sd;
* Transfers the reparse data from a WIM inode (which must represent a reparse
* point) to a NTFS inode.
*/
-static int apply_reparse_data(ntfs_inode *ni, const struct wim_dentry *dentry,
- union wimlib_progress_info *progress_info)
+static int
+apply_reparse_data(ntfs_inode *ni, const struct wim_dentry *dentry,
+ union wimlib_progress_info *progress_info)
{
struct wim_lookup_table_entry *lte;
int ret = 0;
/* Set DOS (short) name if given */
if (dentry_has_short_name(dentry)) {
- mbchar *short_name_mbs;
+ char *short_name_mbs;
size_t short_name_mbs_nbytes;
- ret = utf16le_to_mbs(dentry->short_name,
- dentry->short_name_nbytes,
- &short_name_mbs,
- &short_name_mbs_nbytes);
+ ret = utf16le_to_tstr(dentry->short_name,
+ dentry->short_name_nbytes,
+ &short_name_mbs,
+ &short_name_mbs_nbytes);
if (ret != 0)
goto out_close_dir_ni;
* file. So, this implies that the correct ordering of function calls
* to extract a NTFS file are:
*
- if (file has a DOS name) {
+ * if (file has a DOS name) {
* - Call ntfs_create() to create long name associated with
* the DOS name (this initially creates a POSIX name)
* - Call ntfs_set_ntfs_dos_name() to associate a DOS name