VirtualBox

source: vbox/trunk/src/VBox/Runtime/VBox/logbackdoor-redirect.cpp@ 41561

Last change on this file since 41561 was 36408, checked in by vboxsync, 14 years ago

log rotation review and adjustments: Don't delete any excess files if log roation is disabled - we don't know what these files might be. Moved RTLOGGERFILE into log.c. Keep RTLogCreate simple, anyone needing rotation can use RTLogCreateEx[V]. Made RTLogGetDestinations produce the log rotation bits.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.0 KB
Line 
1/* $Id: logbackdoor-redirect.cpp 36408 2011-03-24 16:25:47Z vboxsync $ */
2/** @file
3 * VirtualBox Runtime - RTLog stubs for the stripped down IPRT used by
4 * RuntimeGuestR3Shared (X11), output is redirected
5 * to the RTLogBackdoor API where possible.
6 */
7
8/*
9 * Copyright (C) 2007-2011 Oracle Corporation
10 *
11 * This file is part of VirtualBox Open Source Edition (OSE), as
12 * available from http://www.virtualbox.org. This file is free software;
13 * you can redistribute it and/or modify it under the terms of the GNU
14 * General Public License (GPL) as published by the Free Software
15 * Foundation, in version 2 as it comes in the "COPYING" file of the
16 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
17 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
18 *
19 * The contents of this file may alternatively be used under the terms
20 * of the Common Development and Distribution License Version 1.0
21 * (CDDL) only, as it comes in the "COPYING.CDDL" file of the
22 * VirtualBox OSE distribution, in which case the provisions of the
23 * CDDL are applicable instead of those of the GPL.
24 *
25 * You may elect to license modified versions of this file under the
26 * terms and conditions of either the GPL or the CDDL or both.
27 */
28
29/*******************************************************************************
30* Header Files *
31*******************************************************************************/
32#include <VBox/log.h>
33#include <VBox/err.h>
34
35
36
37/* All release logging goes to the backdoor logger anyway. */
38RTDECL(PRTLOGGER) RTLogRelDefaultInstance(void)
39{
40 return NULL;
41}
42
43
44/* All logging goes to the backdoor logger anyway. */
45RTDECL(PRTLOGGER) RTLogDefaultInstance(void)
46{
47 return NULL;
48}
49
50/* All logging goes to the backdoor logger anyway. */
51RTDECL(PRTLOGGER) RTLogRelSetDefaultInstance(PRTLOGGER pLogger)
52{
53 return NULL;
54}
55
56RTDECL(void) RTLogRelPrintf(const char *pszFormat, ...)
57{
58 va_list va;
59
60 va_start(va, pszFormat);
61 RTLogBackdoorPrintfV(pszFormat, va);
62 va_end(va);
63}
64
65
66RTDECL(void) RTLogRelPrintfV(const char *pszFormat, va_list va)
67{
68 RTLogBackdoorPrintfV(pszFormat, va);
69}
70
71
72RTDECL(void) RTLogLoggerEx(PRTLOGGER pLogger, unsigned fFlags, unsigned iGroup, const char *pszFormat, ...)
73{
74 va_list va;
75
76 va_start(va, pszFormat);
77 RTLogBackdoorPrintfV(pszFormat, va);
78 va_end(va);
79}
80
81
82RTDECL(void) RTLogPrintf(const char *pszFormat, ...)
83{
84 va_list va;
85
86 va_start(va, pszFormat);
87 RTLogBackdoorPrintfV(pszFormat, va);
88 va_end(va);
89}
90
91
92RTDECL(void) RTLogPrintfV(const char *pszFormat, va_list va)
93{
94 RTLogBackdoorPrintfV(pszFormat, va);
95}
96
97
98/* Do nothing for now. */
99RTDECL(void) RTLogFlush(PRTLOGGER)
100{
101}
102
103/* Do nothing. */
104RTDECL(int) RTLogCreate(PRTLOGGER *ppLogger, RTUINT fFlags, const char *pszGroupSettings,
105 const char *pszEnvVarBase, unsigned cGroups, const char * const * papszGroups,
106 RTUINT fDestFlags, const char *pszFilenameFmt, ...)
107{
108 return VERR_NOT_IMPLEMENTED;
109}
Note: See TracBrowser for help on using the repository browser.

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