Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/dcrt0.cc')
-rw-r--r--winsup/cygwin/dcrt0.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/winsup/cygwin/dcrt0.cc b/winsup/cygwin/dcrt0.cc
index 6e75ccee4..8e1e6271b 100644
--- a/winsup/cygwin/dcrt0.cc
+++ b/winsup/cygwin/dcrt0.cc
@@ -1,7 +1,7 @@
/* dcrt0.cc -- essentially the main() for the Cygwin dll
Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
- 2007, 2008, 2009, 2010, 2011, 2012, 2013 Red Hat, Inc.
+ 2007, 2008, 2009, 2010, 2011, 2012, 2013, 2014 Red Hat, Inc.
This file is part of Cygwin.
@@ -936,14 +936,14 @@ dll_crt0_1 (void *)
/* Allocate cygheap->fdtab */
dtable_init ();
- /* Set internal locale to the environment settings. */
- initial_setlocale ();
-
uinfo_init (); /* initialize user info */
/* Connect to tty. */
tty::init_session ();
+ /* Set internal locale to the environment settings. */
+ initial_setlocale ();
+
if (!__argc)
{
PWCHAR wline = GetCommandLineW ();
@@ -1240,7 +1240,7 @@ cygwin_atexit (void (*fn) (void))
{
int res;
dll *d = dlls.find ((void *) _my_tls.retaddr ());
- res = d ? __cxa_atexit ((void (*) (void *)) fn, NULL, d) : atexit (fn);
+ res = d ? __cxa_atexit ((void (*) (void *)) fn, NULL, d->handle) : atexit (fn);
return res;
}