[FFmpeg-devel] [PATCH] Floating point exception

David Czech davidczech510
Mon Dec 27 22:35:15 CET 2010


>
> a memory breakpoint or in gdb slang a watch point will tell you when a
> variable
> changes. Once we know what exactly set it to 1/0 then we can think about
> what is the best solution
>

I may be doing this wrong, but apparently gdb segfaults after setting a
watch point and going through the program, gdb session attached.
Thanks, David
-------------- next part --------------
Breakpoint 1, output_packet (ist=0x8ae0440, ist_index=0, ost_table=0x8ae04e0, nb_ostreams=1, pkt=0xbfffe974) at ffmpeg.c:1467
1467	    int64_t pkt_pts = AV_NOPTS_VALUE;
(gdb) watch ist->st->codec->time_base.den
Hardware watchpoint 2: ist->st->codec->time_base.den
(gdb) next
1473	    int bps = av_get_bits_per_sample_fmt(ist->st->codec->sample_fmt)>>3;
(gdb) 
1475	    if(ist->next_pts == AV_NOPTS_VALUE)
(gdb) 
1476	        ist->next_pts= ist->pts;
(gdb) 
1478	    if (pkt == NULL) {
(gdb) 
1485	        avpkt = *pkt;
(gdb) 
1488	    if(pkt->dts != AV_NOPTS_VALUE)
(gdb) 
1489	        ist->next_pts = ist->pts = av_rescale_q(pkt->dts, ist->st->time_base, AV_TIME_BASE_Q);
(gdb) 
1490	    if(pkt->pts != AV_NOPTS_VALUE)
(gdb) 
1494	    while (avpkt.size > 0 || (!pkt && ist->next_pts != ist->pts)) {
(gdb) 
1498	        ist->pts= ist->next_pts;
(gdb) 
1500	        if(avpkt.size && avpkt.size != pkt->size &&
(gdb) 
1507	        decoded_data_buf = NULL; /* fail safe */
(gdb) 
1508	        decoded_data_size= 0;
(gdb) 
1509	        data_buf  = avpkt.data;
(gdb) 
1510	        data_size = avpkt.size;
(gdb) 
1511	        subtitle_to_free = NULL;
(gdb) 
1512	        if (ist->decoding_needed) {
(gdb) 
1513	            switch(ist->st->codec->codec_type) {
(gdb) 
1541	                    decoded_data_size = (ist->st->codec->width * ist->st->codec->height * 3) / 2;
(gdb) 
1543	                    avcodec_get_frame_defaults(&picture);
(gdb) 
1544	                    ist->st->codec->reordered_opaque = pkt_pts;
(gdb) 
1545	                    pkt_pts = AV_NOPTS_VALUE;
(gdb) 
1547	                    ret = avcodec_decode_video2(ist->st->codec,
(gdb) 
1549	                    ist->st->quality= picture.quality;
(gdb) 
1550	                    if (ret < 0)
(gdb) 
1552	                    if (!got_picture) {
(gdb) 
1554	                        goto discard_packet;
(gdb) 
1763	    if (pkt == NULL) {
(gdb) 
1848	    return 0;
(gdb) 
1851	}
(gdb) 
Watchpoint 2 deleted because the program has left the block
in which its expression is valid.
Segmentation fault
david at animal:~/Data/GCI/ffmpeg$ # :(



More information about the ffmpeg-devel mailing list