VirtualBox

Changeset 95810 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Jul 25, 2022 1:20:51 PM (2 years ago)
Author:
vboxsync
Message:

IPRT/log-vbox.cpp: Use RTPrinf instead of printf in IPRT_NO_CRT mode for now. bugref:10261

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Runtime/VBox/log-vbox.cpp

    r93115 r95810  
    131131#  include <iprt/win/windows.h>
    132132# elif defined(RT_OS_LINUX)
     133#  include <stdio.h>
    133134#  include <unistd.h>
    134135# elif defined(RT_OS_FREEBSD) || defined(RT_OS_NETBSD)
     
    145146#  define _STRUCTURED_PROC 1
    146147#  undef _FILE_OFFSET_BITS /* procfs doesn't like this */
     148#  include <stdio.h>
    147149#  include <sys/procfs.h>
    148150#  include <unistd.h>
     
    163165# include <iprt/string.h>
    164166# include <iprt/mem.h>
    165 # include <stdio.h>
     167# ifdef IPRT_NO_CRT
     168#  include <iprt/stream.h>
     169# else
     170#  include <stdio.h>
     171# endif
    166172#endif
    167173#if defined(IN_RING0) && defined(RT_OS_DARWIN)
     
    205211     */
    206212#define ASSERT_LOG_GROUP(grp)  ASSERT_LOG_GROUP2(LOG_GROUP_##grp, #grp)
    207 #define ASSERT_LOG_GROUP2(def, str) \
    208     do { if (strcmp(g_apszGroups[def], str)) {printf("%s='%s' expects '%s'\n", #def, g_apszGroups[def], str); RTAssertDoPanic(); } } while (0)
     213#ifdef IPRT_NO_CRT
     214#  define ASSERT_LOG_GROUP2(def, str) \
     215    do { if (strcmp(g_apszGroups[def], str)) { RTPrintf("%s='%s' expects '%s'\n", #def, g_apszGroups[def], str); RTAssertDoPanic(); } } while (0)
     216# else
     217#  define ASSERT_LOG_GROUP2(def, str) \
     218    do { if (strcmp(g_apszGroups[def], str)) { printf("%s='%s' expects '%s'\n", #def, g_apszGroups[def], str); RTAssertDoPanic(); } } while (0)
     219# endif
    209220    ASSERT_LOG_GROUP(DEFAULT);
    210221    ASSERT_LOG_GROUP(AUDIO_MIXER);
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette