VirtualBox

Changeset 15783 in vbox for trunk/src/VBox/Devices/Audio


Ignore:
Timestamp:
Jan 4, 2009 7:39:34 PM (16 years ago)
Author:
vboxsync
Message:

pulse: limit the number of release warnings

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Audio/pulseaudio.c

    r12910 r15783  
    3737#include <stdio.h>
    3838
     39#define MAX_LOG_REL_ERRORS 128
     40
    3941/*
    4042 * We use a g_pMainLoop in a separate thread g_pContext. We have to call functions for
     
    5355    pa_stream  *pStream;
    5456    int         fOpSuccess;
     57    unsigned    cErrors;
    5558} PulseVoice;
    5659
     
    371374    if (cbAvail == (size_t)-1)
    372375    {
    373         LogRel(("Pulse: Failed to determine the writable size: %s\n",
    374                 pa_strerror(pa_context_errno(g_pContext))));
     376        if (pulse->cErrors++ < MAX_LOG_REL_ERRORS)
     377            LogRel(("Pulse: Failed to determine the writable size: %s\n",
     378                    pa_strerror(pa_context_errno(g_pContext))));
    375379        return 0;
    376380    }
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