Revert "decklink: Fix debug logging warnings on Windows"
This reverts commit 845832263ba6b9e135b23e9a29c9d109cb2ee9c4.
The commit broke cross-mingw CI:
https://ci.gstreamer.net/job/GStreamer-master/8659/console
It seems that cross-mingw on Autotools and native-mingw on Meson
disagree about the size of HRESULT. Revert for now till I can
investigate the Meson side of things some more.
diff --git a/sys/decklink/gstdecklink.cpp b/sys/decklink/gstdecklink.cpp
index f39e2fc..2d49bb7 100644
--- a/sys/decklink/gstdecklink.cpp
+++ b/sys/decklink/gstdecklink.cpp
@@ -814,7 +814,7 @@
video_frame->GetStreamTime (&stream_time, &stream_duration,
GST_SECOND);
if (res != S_OK) {
- GST_ERROR ("Failed to get stream time: 0x%08lx", res);
+ GST_ERROR ("Failed to get stream time: 0x%08x", res);
stream_time = GST_CLOCK_TIME_NONE;
stream_duration = GST_CLOCK_TIME_NONE;
}
@@ -828,7 +828,7 @@
&dtc);
if (res != S_OK) {
- GST_DEBUG_OBJECT (videosrc, "Failed to get timecode: 0x%08lx", res);
+ GST_DEBUG_OBJECT (videosrc, "Failed to get timecode: 0x%08x", res);
dtc = NULL;
}
}
@@ -843,7 +843,7 @@
res = audio_packet->GetPacketTime (&packet_time, GST_SECOND);
if (res != S_OK) {
- GST_ERROR ("Failed to get stream time: 0x%08lx", res);
+ GST_ERROR ("Failed to get stream time: 0x%08x", res);
packet_time = GST_CLOCK_TIME_NONE;
}
m_input->got_audio_packet (audiosrc, audio_packet, capture_time,
@@ -950,7 +950,7 @@
ret = decklink->QueryInterface (IID_IDeckLinkInput,
(void **) &devices[i].input.input);
if (ret != S_OK) {
- GST_WARNING ("selected device does not have input interface: 0x%08lx",
+ GST_WARNING ("selected device does not have input interface: 0x%08x",
ret);
} else {
IDeckLinkDisplayModeIterator *mode_iter;
@@ -987,7 +987,7 @@
ret = decklink->QueryInterface (IID_IDeckLinkOutput,
(void **) &devices[i].output.output);
if (ret != S_OK) {
- GST_WARNING ("selected device does not have output interface: 0x%08lx",
+ GST_WARNING ("selected device does not have output interface: 0x%08x",
ret);
} else {
IDeckLinkDisplayModeIterator *mode_iter;
@@ -1025,7 +1025,7 @@
ret = decklink->QueryInterface (IID_IDeckLinkConfiguration,
(void **) &devices[i].input.config);
if (ret != S_OK) {
- GST_WARNING ("selected device does not have config interface: 0x%08lx",
+ GST_WARNING ("selected device does not have config interface: 0x%08x",
ret);
}
@@ -1033,8 +1033,8 @@
(void **) &devices[i].input.attributes);
devices[i].output.attributes = devices[i].input.attributes;
if (ret != S_OK) {
- GST_WARNING ("selected device does not have attributes interface:"
- " 0x%08lx", ret);
+ GST_WARNING ("selected device does not have attributes interface: 0x%08x",
+ ret);
}
ret = iterator->Next (&decklink);
@@ -1272,7 +1272,7 @@
GST_LOG_OBJECT (clock,
"result %" GST_TIME_FORMAT " time %" GST_TIME_FORMAT " last time %"
GST_TIME_FORMAT " offset %" GST_TIME_FORMAT " start time %"
- GST_TIME_FORMAT " (ret: 0x%08lx)", GST_TIME_ARGS (result),
+ GST_TIME_FORMAT " (ret: 0x%08x)", GST_TIME_ARGS (result),
GST_TIME_ARGS (time), GST_TIME_ARGS (last_time), GST_TIME_ARGS (offset),
GST_TIME_ARGS (start_time), ret);
diff --git a/sys/decklink/gstdecklinkaudiosink.cpp b/sys/decklink/gstdecklinkaudiosink.cpp
index 5d1e324..1d63154 100644
--- a/sys/decklink/gstdecklinkaudiosink.cpp
+++ b/sys/decklink/gstdecklinkaudiosink.cpp
@@ -275,8 +275,8 @@
written_sum += written;
} while (len > 0 && res == S_OK);
- GST_LOG_OBJECT (m_ringbuffer->sink, "Wrote %u samples: 0x%08lx",
- written_sum, res);
+ GST_LOG_OBJECT (m_ringbuffer->sink, "Wrote %u samples: 0x%08x", written_sum,
+ res);
gst_audio_ring_buffer_clear (GST_AUDIO_RING_BUFFER_CAST (m_ringbuffer),
seg);
@@ -319,7 +319,7 @@
ret = 0;
}
- GST_DEBUG_OBJECT (self->sink, "Delay: %u (0x%08lx)", ret, res);
+ GST_DEBUG_OBJECT (self->sink, "Delay: %u (0x%08x)", ret, res);
return ret;
}
@@ -414,7 +414,7 @@
ret = self->output->output->EnableAudioOutput (bmdAudioSampleRate48kHz,
sample_depth, spec->info.channels, bmdAudioOutputStreamContinuous);
if (ret != S_OK) {
- GST_WARNING_OBJECT (self->sink, "Failed to enable audio output 0x%08lx",
+ GST_WARNING_OBJECT (self->sink, "Failed to enable audio output 0x%08x",
ret);
return FALSE;
}
@@ -424,7 +424,7 @@
output->SetAudioCallback (new GStreamerAudioOutputCallback (self));
if (ret != S_OK) {
GST_WARNING_OBJECT (self->sink,
- "Failed to set audio output callback 0x%08lx", ret);
+ "Failed to set audio output callback 0x%08x", ret);
return FALSE;
}
diff --git a/sys/decklink/gstdecklinkaudiosrc.cpp b/sys/decklink/gstdecklinkaudiosrc.cpp
index 57f5ecd..43c2d42 100644
--- a/sys/decklink/gstdecklinkaudiosrc.cpp
+++ b/sys/decklink/gstdecklinkaudiosrc.cpp
@@ -404,7 +404,7 @@
self->input->config->SetInt (bmdDeckLinkConfigAudioInputConnection,
conn);
if (ret != S_OK) {
- GST_ERROR ("set configuration (audio input connection): 0x%08lx", ret);
+ GST_ERROR ("set configuration (audio input connection): 0x%08x", ret);
return FALSE;
}
}
@@ -412,7 +412,7 @@
ret = self->input->input->EnableAudioInput (bmdAudioSampleRate48kHz,
sample_depth, self->info.channels);
if (ret != S_OK) {
- GST_WARNING_OBJECT (self, "Failed to enable audio input: 0x%08lx", ret);
+ GST_WARNING_OBJECT (self, "Failed to enable audio input: 0x%08x", ret);
return FALSE;
}
diff --git a/sys/decklink/gstdecklinkvideosink.cpp b/sys/decklink/gstdecklinkvideosink.cpp
index 96c8706..7586bc3 100644
--- a/sys/decklink/gstdecklinkvideosink.cpp
+++ b/sys/decklink/gstdecklinkvideosink.cpp
@@ -403,7 +403,7 @@
ret = self->output->output->EnableVideoOutput (mode->mode, flags);
if (ret != S_OK) {
- GST_WARNING_OBJECT (self, "Failed to enable video output: 0x%08lx", ret);
+ GST_WARNING_OBJECT (self, "Failed to enable video output: 0x%08x", ret);
return FALSE;
}
@@ -611,7 +611,7 @@
&frame);
if (ret != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to create video frame: 0x%08lx", ret));
+ (NULL), ("Failed to create video frame: 0x%08x", ret));
return GST_FLOW_ERROR;
}
@@ -650,7 +650,7 @@
(uint8_t) tc_meta->tc.seconds, (uint8_t) tc_meta->tc.frames, bflags);
if (ret != S_OK) {
GST_ERROR_OBJECT (self,
- "Failed to set timecode %s to video frame: 0x%08lx", tc_str, ret);
+ "Failed to set timecode %s to video frame: 0x%08x", tc_str, ret);
flow_ret = GST_FLOW_ERROR;
g_free (tc_str);
goto out;
@@ -666,7 +666,7 @@
ret = self->output->output->DisplayVideoFrameSync (frame);
if (ret != S_OK) {
GST_ELEMENT_WARNING (self, STREAM, FAILED,
- (NULL), ("Failed to show video frame synchronously: 0x%08lx", ret));
+ (NULL), ("Failed to show video frame synchronously: 0x%08x", ret));
ret = S_OK;
}
}
@@ -679,7 +679,7 @@
running_time, running_time_duration, GST_SECOND);
if (ret != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to schedule frame: 0x%08lx", ret));
+ (NULL), ("Failed to schedule frame: 0x%08x", ret));
flow_ret = GST_FLOW_ERROR;
goto out;
}
@@ -828,7 +828,7 @@
res = self->output->output->StopScheduledPlayback (0, 0, 0);
if (res != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to stop scheduled playback: 0x%08lx", res));
+ (NULL), ("Failed to stop scheduled playback: 0x%08x", res));
gst_object_unref (clock);
return;
}
@@ -843,7 +843,7 @@
GST_SECOND, 1.0);
if (res != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to start scheduled playback: 0x%08lx", res));
+ (NULL), ("Failed to start scheduled playback: 0x%08x", res));
gst_object_unref (clock);
return;
}
@@ -911,7 +911,7 @@
res = self->output->output->StopScheduledPlayback (start_time, 0, GST_SECOND);
if (res != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to stop scheduled playback: 0x%08lx", res));
+ (NULL), ("Failed to stop scheduled playback: 0x%08x", res));
ret = GST_STATE_CHANGE_FAILURE;
}
self->internal_base_time = GST_CLOCK_TIME_NONE;
diff --git a/sys/decklink/gstdecklinkvideosrc.cpp b/sys/decklink/gstdecklinkvideosrc.cpp
index 19fbb64..5f3ff75 100644
--- a/sys/decklink/gstdecklinkvideosrc.cpp
+++ b/sys/decklink/gstdecklinkvideosrc.cpp
@@ -421,7 +421,7 @@
gst_decklink_get_connection (self->connection));
if (ret != S_OK) {
GST_ERROR_OBJECT (self,
- "Failed to set configuration (input source): 0x%08lx", ret);
+ "Failed to set configuration (input source): 0x%08x", ret);
return FALSE;
}
@@ -430,7 +430,7 @@
bmdAnalogVideoFlagCompositeSetup75);
if (ret != S_OK) {
GST_ERROR_OBJECT (self,
- "Failed to set configuration (composite setup): 0x%08lx", ret);
+ "Failed to set configuration (composite setup): 0x%08x", ret);
return FALSE;
}
}
@@ -447,7 +447,7 @@
&autoDetection);
if (ret != S_OK) {
GST_ERROR_OBJECT (self,
- "Failed to get attribute (autodetection): 0x%08lx", ret);
+ "Failed to get attribute (autodetection): 0x%08x", ret);
return FALSE;
}
if (autoDetection)
@@ -465,7 +465,7 @@
format = self->caps_format;
ret = self->input->input->EnableVideoInput (mode->mode, format, flags);
if (ret != S_OK) {
- GST_WARNING_OBJECT (self, "Failed to enable video input: 0x%08lx", ret);
+ GST_WARNING_OBJECT (self, "Failed to enable video input: 0x%08x", ret);
return FALSE;
}
@@ -694,7 +694,7 @@
res = dtc->GetComponents (&hours, &minutes, &seconds, &frames);
if (res != S_OK) {
- GST_ERROR ("Could not get components for timecode %p: 0x%08lx", dtc,
+ GST_ERROR ("Could not get components for timecode %p: 0x%08x", dtc,
res);
f.tc = NULL;
} else {
@@ -1022,7 +1022,7 @@
res = self->input->input->StartStreams ();
if (res != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to start streams: 0x%08lx", res));
+ (NULL), ("Failed to start streams: 0x%08x", res));
return;
}
} else {
@@ -1076,7 +1076,7 @@
res = self->input->input->StopStreams ();
if (res != S_OK) {
GST_ELEMENT_ERROR (self, STREAM, FAILED,
- (NULL), ("Failed to stop streams: 0x%08lx", res));
+ (NULL), ("Failed to stop streams: 0x%08x", res));
ret = GST_STATE_CHANGE_FAILURE;
}
break;