Fix some compiler warnings, and suppress a few others for MSVC
This commit is contained in:
@@ -152,7 +152,7 @@ system_is_multiprocessor()
|
||||
|
||||
#ifdef _WIN32
|
||||
|
||||
void gettimeofday(struct timeval *tv, void *tz)
|
||||
void gettimeofday(struct timeval *tv, void * /* tz */)
|
||||
{
|
||||
union {
|
||||
long long ns100;
|
||||
|
||||
@@ -45,8 +45,12 @@
|
||||
# define R__
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning(disable:4127; disable:4244; disable:4267)
|
||||
#else
|
||||
#pragma GCC diagnostic ignored "-Wconversion"
|
||||
#pragma clang diagnostic ignored "-Wconversion"
|
||||
#endif
|
||||
|
||||
#ifdef __clang__
|
||||
# define RTENTRY__ __attribute__((annotate("realtime")))
|
||||
|
||||
@@ -35,6 +35,10 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning (disable: 4131; disable: 4706)
|
||||
#endif
|
||||
|
||||
int opterr = 1, /* if error message should be printed */
|
||||
optind = 1, /* index into parent argv vector */
|
||||
optopt, /* character checked for validity */
|
||||
|
||||
@@ -54,6 +54,10 @@
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
#pragma warning (disable: 4131; disable: 4996)
|
||||
#endif
|
||||
|
||||
GETOPT_API extern char opterrmsg[128];
|
||||
char opterrmsg[128]; /* last error message is stored here */
|
||||
|
||||
|
||||
@@ -89,8 +89,7 @@ R2Stretcher::ChannelData::construct(const std::set<size_t> &sizes,
|
||||
|
||||
unityResetLow = 16000.f;
|
||||
|
||||
for (std::set<size_t>::const_iterator i = sizes.begin();
|
||||
i != sizes.end(); ++i) {
|
||||
for (i = sizes.begin(); i != sizes.end(); ++i) {
|
||||
ffts[*i] = new FFT(*i);
|
||||
if (sizeof(process_t) == sizeof(double)) {
|
||||
ffts[*i]->initDouble();
|
||||
|
||||
@@ -1006,7 +1006,7 @@ R3Stretcher::consume(bool final)
|
||||
|
||||
while (true) {
|
||||
|
||||
Profiler profiler("R3Stretcher::consume/loop");
|
||||
Profiler profiler2("R3Stretcher::consume/loop");
|
||||
|
||||
int readSpace = cd0->inbuf->getReadSpace();
|
||||
m_log.log(2, "consume: read space", readSpace);
|
||||
|
||||
Reference in New Issue
Block a user