New Defects reported by Coverity Scan for digiKam

scan-admin at coverity.com scan-admin at coverity.com
Sat Apr 16 16:05:48 BST 2022


Hi,

Please find the latest report on new defect(s) introduced to digiKam found with Coverity Scan.

79 new defect(s) introduced to digiKam found with Coverity Scan.
18 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan.

New defect(s) Reported-by: Coverity Scan
Showing 20 of 79 defect(s)


** CID 1504154:  Null pointer dereferences  (FORWARD_NULL)


________________________________________________________________________________________________________
*** CID 1504154:  Null pointer dereferences  (FORWARD_NULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/VideoThread.cpp: 88 in QtAV::VideoThread::setVideoCapture(QtAV::VideoCapture *)()
82         VideoCapture *old = d.capture;
83         d.capture = cap;
84         if (old)
85             disconnect(old, SIGNAL(requested()), this, SLOT(addCaptureTask()));
86         if (cap)
87             connect(cap, SIGNAL(requested()), this, SLOT(addCaptureTask()));
>>>     CID 1504154:  Null pointer dereferences  (FORWARD_NULL)
>>>     Passing null pointer "cap" to "autoSave", which dereferences it.
88         if (cap->autoSave() && cap->name.isEmpty()) {
89             // statistics is already set by AVPlayer
90             cap->setCaptureName(QFileInfo(d.statistics->url).completeBaseName());
91         }
92         return old;
93     }

** CID 1504153:  Null pointer dereferences  (FORWARD_NULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/video/VideoEncoderFFmpeg.cpp: 156 in QtAV::VideoEncoderFFmpegPrivate::open()()


________________________________________________________________________________________________________
*** CID 1504153:  Null pointer dereferences  (FORWARD_NULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/video/VideoEncoderFFmpeg.cpp: 156 in QtAV::VideoEncoderFFmpegPrivate::open()()
150                     break;
151                 }
152             }
153         }
154         //avctx->sample_aspect_ratio =
155         AVPixelFormat hwfmt = AVPixelFormat(-1);
>>>     CID 1504153:  Null pointer dereferences  (FORWARD_NULL)
>>>     Dereferencing null pointer "codec->pix_fmts".
156         if (av_pix_fmt_desc_get(codec->pix_fmts[0])->flags & AV_PIX_FMT_FLAG_HWACCEL)
157             hwfmt = codec->pix_fmts[0];
158         bool use_hwctx = false;
159         if (hwfmt != AVPixelFormat(-1)) {
160     #ifdef HAVE_AVHWCTX
161             const AVHWDeviceType dt = fromHWAName(codec_name.section(QLatin1Char('_'), -1).toUtf8().constData());

** CID 1504152:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/VideoThread.cpp: 51 in QtAV::VideoThreadPrivate::VideoThreadPrivate()()


________________________________________________________________________________________________________
*** CID 1504152:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/VideoThread.cpp: 51 in QtAV::VideoThreadPrivate::VideoThreadPrivate()()
45             AVThreadPrivate()
46           , force_fps(0)
47           , force_dt(0)
48           , capture(0)
49           , filter_context(0)
50         {
>>>     CID 1504152:  Uninitialized members  (UNINIT_CTOR)
>>>     Non-static class member "pts" is not initialized in this constructor nor in any functions that it calls.
51         }
52         ~VideoThreadPrivate() {
53             //not neccesary context is managed by filters.
54             if (filter_context) {
55                 delete filter_context;
56                 filter_context = 0;

** CID 1504151:    (DIVIDE_BY_ZERO)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVDemuxer.cpp: 589 in QtAV::AVDemuxer::seek(long long)()
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVDemuxer.cpp: 585 in QtAV::AVDemuxer::seek(long long)()


________________________________________________________________________________________________________
*** CID 1504151:    (DIVIDE_BY_ZERO)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVDemuxer.cpp: 589 in QtAV::AVDemuxer::seek(long long)()
583         if (upos > startTimeUs() + durationUs() || pos < 0LL) {
584             if (pos >= 0LL && d->input && d->input->isSeekable() && d->input->isVariableSize()) {
585                 qDebug("Seek for variable size hack. %lld %.2f. valid range [%lld, %lld]", upos, double(upos)/double(durationUs()), startTimeUs(), startTimeUs()+durationUs());
586             } else if (d->max_pts > qreal(duration())/1000.0) { //FIXME
587                 qDebug("Seek (%lld) when video duration is growing %lld=>%lld", pos, duration(), qint64(d->max_pts*1000.0));
588             } else {
>>>     CID 1504151:    (DIVIDE_BY_ZERO)
>>>     In expression "(double)upos / (double)this->durationUs()", division by expression "this->durationUs()" which may be zero has undefined behavior.
589                 qWarning("Invalid seek position %lld %.2f. valid range [%lld, %lld]", upos, double(upos)/double(durationUs()), startTimeUs(), startTimeUs()+durationUs());
590                 return false;
591             }
592         }
593         d->eof = false;
594         // no lock required because in AVDemuxThread read and seek are in the same thread
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVDemuxer.cpp: 585 in QtAV::AVDemuxer::seek(long long)()
579         if (!isLoaded())
580             return false;
581         //duration: unit is us (10^-6 s, AV_TIME_BASE)
582         qint64 upos = pos*1000LL; // TODO: av_rescale
583         if (upos > startTimeUs() + durationUs() || pos < 0LL) {
584             if (pos >= 0LL && d->input && d->input->isSeekable() && d->input->isVariableSize()) {
>>>     CID 1504151:    (DIVIDE_BY_ZERO)
>>>     In expression "(double)upos / (double)this->durationUs()", division by expression "this->durationUs()" which may be zero has undefined behavior.
585                 qDebug("Seek for variable size hack. %lld %.2f. valid range [%lld, %lld]", upos, double(upos)/double(durationUs()), startTimeUs(), startTimeUs()+durationUs());
586             } else if (d->max_pts > qreal(duration())/1000.0) { //FIXME
587                 qDebug("Seek (%lld) when video duration is growing %lld=>%lld", pos, duration(), qint64(d->max_pts*1000.0));
588             } else {
589                 qWarning("Invalid seek position %lld %.2f. valid range [%lld, %lld]", upos, double(upos)/double(durationUs()), startTimeUs(), startTimeUs()+durationUs());
590                 return false;

** CID 1504150:  Null pointer dereferences  (REVERSE_INULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVPlayerPrivate.cpp: 557 in QtAV::AVPlayer::Private::tryApplyDecoderPriority(QtAV::AVPlayer*)()


________________________________________________________________________________________________________
*** CID 1504150:  Null pointer dereferences  (REVERSE_INULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVPlayerPrivate.cpp: 557 in QtAV::AVPlayer::Private::tryApplyDecoderPriority(QtAV::AVPlayer*)()
551             delete vd;
552             return true;
553         }
554         vthread->packetQueue()->clear();
555         vthread->setDecoder(vd);
556         // MUST delete decoder after video thread set the decoder to ensure the deleted vdec will not be used in vthread!
>>>     CID 1504150:  Null pointer dereferences  (REVERSE_INULL)
>>>     Null-checking "this->vdec" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
557         if (vdec)
558             delete vdec;
559         vdec = vd;
560         QObject::connect(vdec, SIGNAL(error(QtAV::AVError)), player, SIGNAL(error(QtAV::AVError)));
561         initVideoStatistics(demuxer.videoStream());
562         // If no seek, drop packets until a key frame packet is found. But we may drop too many packets, and also a/v sync is a problem.

** CID 1504149:  Incorrect expression  (PRECEDENCE_ERROR)
/home/gilles/Devel/8.x/core/libs/rawengine/libraw/samples/dcraw_emu.cpp: 512 in main()


________________________________________________________________________________________________________
*** CID 1504149:  Incorrect expression  (PRECEDENCE_ERROR)
/home/gilles/Devel/8.x/core/libs/rawengine/libraw/samples/dcraw_emu.cpp: 512 in main()
506     		if (!mapping.map)
507     		{
508     			fprintf(stderr, "Cannot map %s\n", argv[arg]);
509     			close_mapping(mapping);
510     			continue;
511     		}
>>>     CID 1504149:  Incorrect expression  (PRECEDENCE_ERROR)
>>>     Evaluates as: "ret = (RawProcessor.open_buffer(mapping.map, mapping.fsize) != LIBRAW_SUCCESS)", because "!=" has higher operator precedence than "=". The context suggests that this might be in error.
512           if ((ret = RawProcessor.open_buffer(mapping.map,mapping.fsize) !=
513                      LIBRAW_SUCCESS))
514           {
515             fprintf(stderr, "Cannot open_buffer %s: %s\n", argv[arg], libraw_strerror(ret));
516     		close_mapping(mapping);
517             continue; // no recycle b/c open file will recycle itself

** CID 1504148:  Memory - illegal accesses  (UNINIT)


________________________________________________________________________________________________________
*** CID 1504148:  Memory - illegal accesses  (UNINIT)
/home/gilles/Devel/8.x/core/libs/dngwriter/extra/dng_sdk/dng_image_writer.cpp: 1712 in exif_tag_set::exif_tag_set(dng_tiff_directory &, const dng_exif &, bool, const void *, unsigned int, bool)()
1706     			{
1707     			fGPSIFD.Add (&fGPSHPositioningError);
1708     			}
1709     
1710     		}
1711     
>>>     CID 1504148:  Memory - illegal accesses  (UNINIT)
>>>     Using uninitialized element of array "this->fGPSIFD.fTag" when calling "AddLinks".
1712     	AddLinks (directory);
1713     
1714     	}
1715     
1716     /******************************************************************************/
1717     

** CID 1504147:  Uninitialized variables  (UNINIT)


________________________________________________________________________________________________________
*** CID 1504147:  Uninitialized variables  (UNINIT)
/usr/include/eigen3/Eigen/src/Core/ProductEvaluators.h: 1004 in Eigen::internal::permutation_matrix_product<Eigen::Map<Eigen::Matrix<double, (int)-1, (int)1, (int)0, (int)-1, (int)1>, (int)0, Eigen::Stride<(int)0, (int)0>>, (int)1, (bool)0, Eigen::DenseShape>::run<Eigen::Matrix<double, (int)-1, (int)1, (int)0, (int)-1, (int)1>, Eigen::PermutationMatrix<(int)-1, (int)-1, int>>(T1 &, const T2 &, const Eigen::Map<Eigen::Matrix<double, (int)-1, (int)1, (int)0, (int)-1, (int)1>, (int)0, Eigen::Stride<(int)0, (int)0>> &)()
998             }
999           }
1000           else
1001           {
1002             for(Index i = 0; i < n; ++i)
1003             {
>>>     CID 1504147:  Uninitialized variables  (UNINIT)
>>>     Using uninitialized value "mat". Field "mat.m_stride" is uninitialized when calling "Block".
1004               Block<Dest, Side==OnTheLeft ? 1 : Dest::RowsAtCompileTime, Side==OnTheRight ? 1 : Dest::ColsAtCompileTime>
1005                    (dst, ((Side==OnTheLeft) ^ Transposed) ? perm.indices().coeff(i) : i)
1006     
1007               =
1008     
1009               Block<const MatrixTypeCleaned,Side==OnTheLeft ? 1 : MatrixTypeCleaned::RowsAtCompileTime,Side==OnTheRight ? 1 : MatrixTypeCleaned::ColsAtCompileTime>

** CID 1504146:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/QtAV/private/VideoShader_p.h: 72 in QtAV::VideoShaderPrivate::VideoShaderPrivate()()


________________________________________________________________________________________________________
*** CID 1504146:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/QtAV/private/VideoShader_p.h: 72 in QtAV::VideoShaderPrivate::VideoShaderPrivate()()
66             , u_colorMatrix(-1)
67             , u_to8(-1)
68             , u_opacity(-1)
69             , u_c(-1)
70             , material_type(0)
71             , texture_target(GL_TEXTURE_2D)
>>>     CID 1504146:  Uninitialized members  (UNINIT_CTOR)
>>>     Non-static class member "u_textureSize" is not initialized in this constructor nor in any functions that it calls.
72         {}
73         virtual ~VideoShaderPrivate() {
74             if (owns_program && program) {
75                 if (QOpenGLContext::currentContext()) {
76                     // FIXME: may be not called from renderering thread. so we still have to detach shaders
77                     program->removeAllShaders();

** CID 1504145:  Low impact quality  (MISSING_MOVE_ASSIGNMENT)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/QtAV/AudioFormat.h: 37 in ()


________________________________________________________________________________________________________
*** CID 1504145:  Low impact quality  (MISSING_MOVE_ASSIGNMENT)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/QtAV/AudioFormat.h: 37 in ()
31     class QDebug;
32     QT_END_NAMESPACE
33     namespace QtAV
34     {
35     
36     class AudioFormatPrivate;
>>>     CID 1504145:  Low impact quality  (MISSING_MOVE_ASSIGNMENT)
>>>     Class "QtAV::AudioFormat" may benefit from adding a move assignment operator. See other events which show the copy assignment operator being applied to rvalues, where a move assignment may be faster.
37     class Q_AV_EXPORT AudioFormat
38     {
39         enum { kSize = 12, kFloat = 1<<(kSize+1), kUnsigned = 1<<(kSize+2), kPlanar = 1<<(kSize+3), kByteOrder = 1<<(kSize+4) };
40     public:
41         /*!
42          * \brief The SampleFormat enum

** CID 1504144:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/subtitle/SubImage.cpp: 35 in QtAV::SubImage::SubImage(int, int, int, int, int)()


________________________________________________________________________________________________________
*** CID 1504144:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/subtitle/SubImage.cpp: 35 in QtAV::SubImage::SubImage(int, int, int, int, int)()
29     SubImage::SubImage(int x, int y, int w, int h, int stride)
30         : x(x)
31         , y(y)
32         , w(w)
33         , h(h)
34         , stride(stride)
>>>     CID 1504144:  Uninitialized members  (UNINIT_CTOR)
>>>     Non-static class member "color" is not initialized in this constructor nor in any functions that it calls.
35     {}
36     
37     SubImageSet::SubImageSet(int width, int height, Format format)
38         : fmt(format)
39         , w(width)
40         , h(height)

** CID 1504143:  Incorrect expression  (DIVIDE_BY_ZERO)


________________________________________________________________________________________________________
*** CID 1504143:  Incorrect expression  (DIVIDE_BY_ZERO)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/opengl/SubImagesGeometry.cpp: 197 in QtAV::SubImagesGeometry::generateVertexData(const QRect &, bool, int)()
191         const float sx = float(rect.width())/float(m_images.width());
192         const float sy = float(rect.height())/float(m_images.height());
193         vd = (VertexData*)vertexData();
194         foreach (const SubImage& i, m_images.images) {
195             //qDebug() << rect;
196             //qDebug("i: %d,%d", i.x, i.y);
>>>     CID 1504143:  Incorrect expression  (DIVIDE_BY_ZERO)
>>>     In function call "SetVertexPositionAndNormalize", division by expression "this->m_h" which may be zero has undefined behavior.
197             vd = SetVertexPositionAndNormalize(vd, dx0 + float(i.x)*sx, dy0 + float(i.y)*sy, i.w*sx, i.h*sy, m_w, m_h, useIndecies);
198             m_normalized = true;
199         }
200         return true;
201     }
202     

** CID 1504142:  Uninitialized variables  (UNINIT)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/video/VideoDecoderVAAPI.cpp: 202 in QtAV::VideoDecoderVAAPIPrivate::VideoDecoderVAAPIPrivate()()


________________________________________________________________________________________________________
*** CID 1504142:  Uninitialized variables  (UNINIT)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/video/VideoDecoderVAAPI.cpp: 202 in QtAV::VideoDecoderVAAPIPrivate::VideoDecoderVAAPIPrivate()()
196         {
197             if (VAAPI_DRM::isLoaded())
198                 display_type = VideoDecoderVAAPI::DRM;
199             if (VAAPI_X11::isLoaded())
200                 display_type = VideoDecoderVAAPI::X11;
201     #ifndef QT_NO_OPENGL
>>>     CID 1504142:  Uninitialized variables  (UNINIT)
>>>     Using uninitialized value "this->display_type".
202             if (display_type == VideoDecoderVAAPI::X11) {
203     #if VA_X11_INTEROP
204                 copy_mode = VideoDecoderFFmpegHW::ZeroCopy; //TFP if va<0.38
205     #endif //VA_X11_INTEROP
206             }
207     #if QTAV_HAVE(EGL_CAPI)

** CID 1504141:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/opengl/OpenGLVideo.cpp: 59 in QtAV::OpenGLVideoPrivate::OpenGLVideoPrivate()()


________________________________________________________________________________________________________
*** CID 1504141:  Uninitialized members  (UNINIT_CTOR)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/opengl/OpenGLVideo.cpp: 59 in QtAV::OpenGLVideoPrivate::OpenGLVideoPrivate()()
53             , valiad_tex_width(1.0)
54             , mesh_type(OpenGLVideo::RectMesh)
55             , geometry(NULL)
56             , gr(NULL)
57             , user_shader(NULL)
58         {
>>>     CID 1504141:  Uninitialized members  (UNINIT_CTOR)
>>>     Non-static class member "has_a" is not initialized in this constructor nor in any functions that it calls.
59         }
60         ~OpenGLVideoPrivate() {
61             if (material) {
62                 delete material;
63                 material = 0;
64             }

** CID 1504140:  Security best practices violations  (STRING_OVERFLOW)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/opengl/gl_api.cpp: 60 in QtAV::GetProcAddressWithExt(void *(*)(const char *), const char *)()


________________________________________________________________________________________________________
*** CID 1504140:  Security best practices violations  (STRING_OVERFLOW)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/opengl/gl_api.cpp: 60 in QtAV::GetProcAddressWithExt(void *(*)(const char *), const char *)()
54     #ifdef __APPLE__
55             , "APPLE"
56     #endif
57             , NULL
58         };
59         char f[512];
>>>     CID 1504140:  Security best practices violations  (STRING_OVERFLOW)
>>>     You might overrun the 512-character fixed-size string "f" by copying "name" without checking the length.
60         memcpy(f, name, strlen(name));
61         char* const p = f + strlen(name);
62         for (int i = 0; ext[i]; ++i) {
63             memcpy(p, ext[i], sizeof(ext[i]) + 1); //copy trail '\0'
64             fp = get(f);
65             if (fp) {

** CID 1504139:  Control flow issues  (UNREACHABLE)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVThread.cpp: 335 in QtAV::AVThread::tryPause(unsigned long)()


________________________________________________________________________________________________________
*** CID 1504139:  Control flow issues  (UNREACHABLE)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVThread.cpp: 335 in QtAV::AVThread::tryPause(unsigned long)()
329         DPTR_D(AVThread);
330         if (!isPaused())
331             return false;
332         QMutexLocker lock(&d.mutex);
333         Q_UNUSED(lock);
334         return d.cond.wait(&d.mutex, timeout);
>>>     CID 1504139:  Control flow issues  (UNREACHABLE)
>>>     This code cannot be reached: "QtAV::Internal::Logger cons...".
335         qDebug("paused thread waked up!!!");
336         return true;
337     }
338     
339     bool AVThread::processNextTask()
340     {

** CID 1504138:  Incorrect expression  (USELESS_CALL)


________________________________________________________________________________________________________
*** CID 1504138:  Incorrect expression  (USELESS_CALL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AVDemuxThread.cpp: 239 in QtAV::AVDemuxThread::stepBackward()()
233             qreal pts;
234         };
235     
236         pause(true);
237     
238         t->packetQueue()->clear(); // will put new packets before task run
>>>     CID 1504138:  Incorrect expression  (USELESS_CALL)
>>>     Calling "t->packetQueue()" is only useful for its return value, which is ignored.
239         t->packetQueue();
240         Packet pkt;
241         pkt.pts = pre_pts;
242         t->packetQueue()->put(pkt); // clear and put a seek packet to ensure not frames other than previous frame will be decoded and rendered
243         video_thread->pause(false);
244         newSeekRequest(new stepBackwardTask(this, pre_pts));

** CID 1504137:  Integer handling issues  (DIVIDE_BY_ZERO)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AudioFormat.cpp: 373 in QtAV::AudioFormat::durationForBytes(int) const()


________________________________________________________________________________________________________
*** CID 1504137:  Integer handling issues  (DIVIDE_BY_ZERO)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/AudioFormat.cpp: 373 in QtAV::AudioFormat::durationForBytes(int) const()
367     qint64 AudioFormat::durationForBytes(qint32 bytes) const
368     {
369         if (!isValid() || bytes <= 0)
370             return 0;
371     
372         // We round the byte count to ensure whole frames
>>>     CID 1504137:  Integer handling issues  (DIVIDE_BY_ZERO)
>>>     In expression "bytes / this->bytesPerFrame()", division by expression "this->bytesPerFrame()" which may be zero has undefined behavior.
373         return qint64(kHz * (bytes / bytesPerFrame())) / sampleRate();
374     }
375     
376     /*!
377         Returns the number of bytes required for \a frameCount frames of this format.
378     

** CID 1504136:  Null pointer dereferences  (REVERSE_INULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/subtitle/SubtitleProcessorFFmpeg.cpp: 389 in QtAV::SubtitleProcessorFFmpeg::processSubtitle()()


________________________________________________________________________________________________________
*** CID 1504136:  Null pointer dereferences  (REVERSE_INULL)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/subtitle/SubtitleProcessorFFmpeg.cpp: 389 in QtAV::SubtitleProcessorFFmpeg::processSubtitle()()
383                 qWarning("Failed to find subtitle codec %d", codec_ctx->codec_id);
384             return false;
385         }
386         qDebug("found subtitle decoder '%s'", dec_desc->name);
387         // AV_CODEC_PROP_TEXT_SUB: ffmpeg >= 2.0
388     #ifdef AV_CODEC_PROP_TEXT_SUB
>>>     CID 1504136:  Null pointer dereferences  (REVERSE_INULL)
>>>     Null-checking "dec_desc" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
389         if (dec_desc && !(dec_desc->props & AV_CODEC_PROP_TEXT_SUB)) {
390             qWarning("Only text based subtitles are currently supported");
391             return false;
392         }
393     #endif
394         AVDictionary *codec_opts = NULL;

** CID 1504135:    (UNREACHABLE)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/audio/AudioDecoderFFmpeg.cpp: 125 in QtAV::AudioDecoderFFmpeg::decode(const QtAV::Packet &)()
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/audio/AudioDecoderFFmpeg.cpp: 131 in QtAV::AudioDecoderFFmpeg::decode(const QtAV::Packet &)()


________________________________________________________________________________________________________
*** CID 1504135:    (UNREACHABLE)
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/audio/AudioDecoderFFmpeg.cpp: 125 in QtAV::AudioDecoderFFmpeg::decode(const QtAV::Packet &)()
119             qWarning("[AudioDecoder] got_frame_ptr=false. decoded: %d, un: %d %s", ret, d.undecoded_size, av_err2str(ret));
120             return !packet.isEOF();
121         }
122     #if USE_AUDIO_FRAME
123         return true;
124     #endif
>>>     CID 1504135:    (UNREACHABLE)
>>>     This code cannot be reached: "d.resampler->setInSampesPer...".
125         d.resampler->setInSampesPerChannel(d.frame->nb_samples);
126         if (!d.resampler->convert((const quint8**)d.frame->extended_data)) {
127             return false;
128         }
129         d.decoded = d.resampler->outData();
130         return true;
/home/gilles/Devel/8.x/core/libs/video/qtav/src/codec/audio/AudioDecoderFFmpeg.cpp: 131 in QtAV::AudioDecoderFFmpeg::decode(const QtAV::Packet &)()
125         d.resampler->setInSampesPerChannel(d.frame->nb_samples);
126         if (!d.resampler->convert((const quint8**)d.frame->extended_data)) {
127             return false;
128         }
129         d.decoded = d.resampler->outData();
130         return true;
>>>     CID 1504135:    (UNREACHABLE)
>>>     This code cannot be reached: "return !d.decoded.isEmpty();".
131         return !d.decoded.isEmpty();
132     }
133     
134     AudioFrame AudioDecoderFFmpeg::frame()
135     {
136         DPTR_D(AudioDecoderFFmpeg);


________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u15810271.ct.sendgrid.net/ls/click?upn=HRESupC-2F2Czv4BOaCWWCy7my0P0qcxCbhZ31OYv50yp2OAl-2Fauo86CB28HCT0-2BnD-2F6eFMYt863B1-2B0FLvU5y-2FRWSl8rMA4vGwCkGPp0f1hg-3DIm3j_IpEMwFcbl-2BY9RHaL2m6a3nuAxB4hfm4MTniX0gHjADWCpb4LzP0D7Q3MCtpbGpEAI6UqICI7fclTOuWQSz9Z96n02WTRZwgffn6U-2FRPN2CRHfwy52Hlk7Nmw0VVv2emLsO8kGH0beZOm7qxmmzgPj7wQC0lHZLTx-2FGLz-2BDcmRVu7BOoTVinG6hEpZx6-2BNCmV-2Fx-2BTHskongYILjnxaJ1lfQ-3D-3D



More information about the Digikam-devel mailing list