Signed-off-by: Francois Gouget fgouget@free.fr --- dlls/msvcrt/iob.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/msvcrt/iob.c b/dlls/msvcrt/iob.c index c02913b45ab..f8d46ad6e46 100644 --- a/dlls/msvcrt/iob.c +++ b/dlls/msvcrt/iob.c @@ -30,7 +30,7 @@ extern MSVCRT_FILE * CDECL __p__iob(void); /********************************************************************* * __acrt_iob_func(UCRTBASE.@) */ -MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) +static MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) { return __p__iob() + idx; }
Hi Francois,
On 5/9/19 10:59 AM, Francois Gouget wrote:
Signed-off-by: Francois Gouget fgouget@free.fr
dlls/msvcrt/iob.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/msvcrt/iob.c b/dlls/msvcrt/iob.c index c02913b45ab..f8d46ad6e46 100644 --- a/dlls/msvcrt/iob.c +++ b/dlls/msvcrt/iob.c @@ -30,7 +30,7 @@ extern MSVCRT_FILE * CDECL __p__iob(void); /*********************************************************************
__acrt_iob_func(UCRTBASE.@)
*/ -MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) +static MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) { return __p__iob() + idx; }
This is part of a static library and I think that it's intentionally not static.
Jacek
On Thu, 9 May 2019, Jacek Caban wrote:
Hi Francois,
On 5/9/19 10:59 AM, Francois Gouget wrote:
Signed-off-by: Francois Gouget fgouget@free.fr
dlls/msvcrt/iob.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/msvcrt/iob.c b/dlls/msvcrt/iob.c index c02913b45ab..f8d46ad6e46 100644 --- a/dlls/msvcrt/iob.c +++ b/dlls/msvcrt/iob.c @@ -30,7 +30,7 @@ extern MSVCRT_FILE * CDECL __p__iob(void); /*********************************************************************
__acrt_iob_func(UCRTBASE.@)
*/ -MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) +static MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) { return __p__iob() + idx; }
This is part of a static library and I think that it's intentionally not static.
It's used to set either _imp____acrt_iob_func or __imp___acrt_iob_func. I would have expected it to only be used through these variables.
On 5/9/19 2:38 PM, Francois Gouget wrote:
On Thu, 9 May 2019, Jacek Caban wrote:
Hi Francois,
On 5/9/19 10:59 AM, Francois Gouget wrote:
Signed-off-by: Francois Gouget fgouget@free.fr
dlls/msvcrt/iob.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/msvcrt/iob.c b/dlls/msvcrt/iob.c index c02913b45ab..f8d46ad6e46 100644 --- a/dlls/msvcrt/iob.c +++ b/dlls/msvcrt/iob.c @@ -30,7 +30,7 @@ extern MSVCRT_FILE * CDECL __p__iob(void); /********************************************************************* * __acrt_iob_func(UCRTBASE.@) */ -MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) +static MSVCRT_FILE * CDECL __acrt_iob_func(unsigned idx) { return __p__iob() + idx; }
This is part of a static library and I think that it's intentionally not static.
It's used to set either _imp____acrt_iob_func or __imp___acrt_iob_func. I would have expected it to only be used through these variables.
For the code that consequently uses dllimport attribute, that should be the case. Otherwise, if callee didn't generate code expecting dllimport, linker is capable of handling that. But if we export it ourselves (as typical importlibs do), it will not have to and the code will be slightly better.
Jacek