mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-09 17:38:00 +00:00
Windows: add filename_to_wstr().
The wide-string version of filename_to_str(): given a Filename, return a reference to its contained wchar_t string form.
This commit is contained in:
parent
1ef0fbaafc
commit
22dfc46fb2
@ -66,6 +66,7 @@ struct Filename {
|
|||||||
char *cpath, *utf8path;
|
char *cpath, *utf8path;
|
||||||
};
|
};
|
||||||
Filename *filename_from_wstr(const wchar_t *str);
|
Filename *filename_from_wstr(const wchar_t *str);
|
||||||
|
const wchar_t *filename_to_wstr(const Filename *fn);
|
||||||
FILE *f_open(const Filename *filename, const char *mode, bool isprivate);
|
FILE *f_open(const Filename *filename, const char *mode, bool isprivate);
|
||||||
|
|
||||||
#ifndef SUPERSEDE_FONTSPEC_FOR_TESTING
|
#ifndef SUPERSEDE_FONTSPEC_FOR_TESTING
|
||||||
|
@ -47,6 +47,11 @@ const char *filename_to_str(const Filename *fn)
|
|||||||
return fn->cpath; /* FIXME */
|
return fn->cpath; /* FIXME */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const wchar_t *filename_to_wstr(const Filename *fn)
|
||||||
|
{
|
||||||
|
return fn->wpath;
|
||||||
|
}
|
||||||
|
|
||||||
bool filename_equal(const Filename *f1, const Filename *f2)
|
bool filename_equal(const Filename *f1, const Filename *f2)
|
||||||
{
|
{
|
||||||
/* wpath is primary: two filenames refer to the same file if they
|
/* wpath is primary: two filenames refer to the same file if they
|
||||||
|
Loading…
Reference in New Issue
Block a user