Skip to content

Commit

Permalink
Fix two new cppcheck warnings about values supplied to usleep being t…
Browse files Browse the repository at this point in the history
…oo large.
  • Loading branch information
stuartm committed Jul 22, 2013
1 parent 30d7cc4 commit 3186c98
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion mythtv/libs/libmyth/audio/audiooutputca.cpp
Expand Up @@ -280,7 +280,7 @@ bool AudioOutputCA::OpenDevice()
if (result < 0)
{
d->CloseAnalog();
usleep(1000 * 1000);
usleep((1000 * 1000) - 1); // Argument to usleep must be less than 1 million
}
}
deviceOpened = (result > 0);
Expand Down
2 changes: 1 addition & 1 deletion mythtv/libs/libmythtv/diseqc.cpp
Expand Up @@ -36,7 +36,7 @@
// DiSEqC sleep intervals per eutelsat spec
#define DISEQC_SHORT_WAIT (15 * 1000)
#define DISEQC_LONG_WAIT (100 * 1000)
#define DISEQC_POWER_OFF_WAIT (1000 * 1000)
#define DISEQC_POWER_OFF_WAIT ((1000 * 1000) - 1)
#define DISEQC_POWER_ON_WAIT (500 * 1000)

// Number of times to retry ioctls after receiving ETIMEDOUT before giving up
Expand Down

0 comments on commit 3186c98

Please sign in to comment.