* dtable.cc: Mark some const variables as static.

* environ.cc (conv_start_chars): Move to shared cygwin region and initialize at
compile time.
(match_first_char): New generic function for querying conv_start_chars.
(posify_maybe): Rename from posify.
(environ_init): Remove conv_envvars initialization.  Don't check
conv_start_chars, just allow posify_maybe to make the decision.
* fhandler_console.cc (__vt100_conv): Fix formatting.  Mark as const.
This commit is contained in:
Christopher Faylor
2011-08-19 18:19:22 +00:00
parent 34dc27f95d
commit c8a66289e4
4 changed files with 65 additions and 18 deletions

View File

@@ -38,12 +38,12 @@ static const NO_COPY DWORD std_consts[] = {STD_INPUT_HANDLE, STD_OUTPUT_HANDLE,
static bool handle_to_fn (HANDLE, char *);
#define WCLEN(x) ((sizeof (x) / sizeof (WCHAR)) - 1)
char unknown_file[] = "some disk file";
const WCHAR DEV_NULL[] = L"\\Device\\Null";
static const char unknown_file[] = "some disk file";
static const WCHAR DEV_NULL[] = L"\\Device\\Null";
static const WCHAR DEV_SOCKET[] = L"\\Device\\Afd";
const WCHAR DEVICE_PREFIX[] = L"\\device\\";
const size_t DEVICE_PREFIX_LEN WCLEN (DEVICE_PREFIX);
static const WCHAR DEVICE_PREFIX[] = L"\\device\\";
static const size_t DEVICE_PREFIX_LEN WCLEN (DEVICE_PREFIX);
static const WCHAR DEV_NAMED_PIPE[] = L"\\Device\\NamedPipe\\";
static const size_t DEV_NAMED_PIPE_LEN = WCLEN (DEV_NAMED_PIPE);