* path.h (path_conv::set_name): Declare new function.
* path.cc (path_conv::set_name): Define new function. * fhandler.h (fhandler_dev_null::open): Declare new function. * fhandler.cc (fhandler_dev_null::open): Define new function.
This commit is contained in:
parent
4faae8d6e9
commit
17dc5be5e9
|
@ -1,3 +1,10 @@
|
||||||
|
2005-01-31 Christopher Faylor <cgf@timesys.com>
|
||||||
|
|
||||||
|
* path.h (path_conv::set_name): Declare new function.
|
||||||
|
* path.cc (path_conv::set_name): Define new function.
|
||||||
|
* fhandler.h (fhandler_dev_null::open): Declare new function.
|
||||||
|
* fhandler.cc (fhandler_dev_null::open): Define new function.
|
||||||
|
|
||||||
2005-01-31 Christopher Faylor <cgf@timesys.com>
|
2005-01-31 Christopher Faylor <cgf@timesys.com>
|
||||||
|
|
||||||
* smallprint.c (rnarg): Use long rather than unsigned long so that we
|
* smallprint.c (rnarg): Use long rather than unsigned long so that we
|
||||||
|
|
|
@ -1421,6 +1421,15 @@ fhandler_dev_null::dump (void)
|
||||||
paranoid_printf ("here");
|
paranoid_printf ("here");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
fhandler_dev_null::open (int flags, mode_t mode)
|
||||||
|
{
|
||||||
|
char posix[strlen (get_name ()) + 1];
|
||||||
|
strcpy (posix, get_name ());
|
||||||
|
pc.set_name ("NUL", posix);
|
||||||
|
return fhandler_base::open_9x (flags, mode);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
fhandler_base::set_no_inheritance (HANDLE &h, int not_inheriting)
|
fhandler_base::set_no_inheritance (HANDLE &h, int not_inheriting)
|
||||||
{
|
{
|
||||||
|
|
|
@ -951,6 +951,7 @@ class fhandler_dev_null: public fhandler_base
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
fhandler_dev_null ();
|
fhandler_dev_null ();
|
||||||
|
int open (int, mode_t);
|
||||||
|
|
||||||
void dump ();
|
void dump ();
|
||||||
select_record *select_read (select_record *s);
|
select_record *select_read (select_record *s);
|
||||||
|
|
|
@ -942,6 +942,15 @@ out:
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
path_conv::set_name (const char *win32, const char *posix)
|
||||||
|
{
|
||||||
|
if (!normalized_path_size && normalized_path)
|
||||||
|
cfree (normalized_path);
|
||||||
|
strcpy (path, win32);
|
||||||
|
set_normalized_path (posix, false);
|
||||||
|
}
|
||||||
|
|
||||||
path_conv::~path_conv ()
|
path_conv::~path_conv ()
|
||||||
{
|
{
|
||||||
if (!normalized_path_size && normalized_path)
|
if (!normalized_path_size && normalized_path)
|
||||||
|
|
|
@ -191,6 +191,7 @@ class path_conv
|
||||||
{path[0] = '\0';}
|
{path[0] = '\0';}
|
||||||
|
|
||||||
~path_conv ();
|
~path_conv ();
|
||||||
|
void set_name (const char *win32, const char *posix);
|
||||||
inline char *get_win32 () { return path; }
|
inline char *get_win32 () { return path; }
|
||||||
PUNICODE_STRING get_nt_native_path (UNICODE_STRING &upath);
|
PUNICODE_STRING get_nt_native_path (UNICODE_STRING &upath);
|
||||||
operator char *() {return path;}
|
operator char *() {return path;}
|
||||||
|
|
Loading…
Reference in New Issue