Opened 5 years ago

Closed 5 years ago

#608 closed defect (fixed)

Crash reading from UDP

Reported by: Krieger Owned by:
Priority: normal Component: avformat
Version: git-master Keywords: udp
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

av_read_frame function crashes sometimes while reading source media via UDP.
This is possible to reproduce in following way:

  1. Launch this on one terminal:

ffmpeg -f mpegts -i udp://127.0.0.1:12345 -f mpegts out.ts

  1. When it hangs, launch this on another terminal:

cat test.ts | nc -u 127.0.0.1 12345

Below you can see my patch that fixes the issue.

  1. S. Libav fork lacks this bug :)

$ gdb /usr/local/src/ffmpeg_git_debug/ffmpeg_g
GNU gdb (Gentoo 7.2 p1) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.gentoo.org/>...
Reading symbols from /usr/local/src/ffmpeg_git_debug/ffmpeg_g...done.
(gdb) r -f mpegts -i udp://127.0.0.1:12345 -f mpegts out.ts -loglevel 99 -v 9
Starting program: /usr/local/src/ffmpeg_git_debug/ffmpeg_g -f mpegts -i udp://127.0.0.1:12345 -f mpegts out.ts -loglevel 99 -v 9
[Thread debugging using libthread_db enabled]
ffmpeg version N-34399-g988f585, Copyright (c) 2000-2011 the FFmpeg developers

built on Nov 3 2011 06:34:16 with gcc 4.4.5
configuration: --disable-optimizations --extra-cflags='-g -ggdb -O0' --prefix=/usr --libdir=/usr/lib --shlibdir=/usr/lib --mandir=/usr/share/man --enable-static --enable-shared --enable-gpl --enable-version3 --enable-postproc --enable-avfilter --disable-stripping --disable-doc --disable-vaapi --disable-vdpau --enable-libmp3lame --enable-libx264 --enable-libxvid --disable-indev=v4l --disable-indev=v4l2 --disable-indev=jack --enable-x11grab --enable-pthreads --enable-librtmp --disable-altivec --enable-libfaac --enable-nonfree --disable-asm --disable-stripping
libavutil 51. 23. 0 / 51. 23. 0
libavcodec 53. 27. 0 / 53. 27. 0
libavformat 53. 18. 0 / 53. 18. 0
libavdevice 53. 4. 0 / 53. 4. 0
libavfilter 2. 45. 3 / 2. 45. 3
libswscale 2. 1. 0 / 2. 1. 0
libpostproc 51. 2. 0 / 51. 2. 0

[New Thread 0x7ffff38d6700 (LWP 26196)]
[udp @ 0x626c60] Part of datagram lost due to insufficient buffer size

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff57ed23b in memcpy () from /lib64/libc.so.6
(gdb) bt
#0 0x00007ffff57ed23b in memcpy () from /lib64/libc.so.6
#1 0x00007ffff5f6ecb3 in av_fifo_generic_read (f=0x636e50, dest=0x7fffffffc3e0, buf_size=-222357468,

func=0) at libavutil/fifo.c:113

#2 0x00007ffff7698530 in udp_read (h=0x626c60,

buf=0x7fffffffc3e0 "o\023*J\005\214\004q\370t7P|\355y\207Y\206R\202A\365\017
_\341\016RG\037\377\020", size=6720) at libavformat/udp.c:557

#3 0x00007ffff75cc81a in retry_transfer_wrapper (h=0x626c60,

buf=0x7fffffffc3e0 "o\023*J\005\214\004q\370t7P|\355y\207Y\206R\202A\365\017
_\341\016RG\037\377\020", size=6720, size_min=1, transfer_func=0x7ffff769843e <udp_read>) at libavformat/avio.c:269

#4 0x00007ffff75cc91d in ffurl_read (h=0x626c60,

buf=0x7fffffffc3e0 "o\023*J\005\214\004q\370t7P|\355y\207Y\206R\202A\365\017
_\341\016RG\037\377\020", size=6720) at libavformat/avio.c:295

#5 0x00007ffff75ce972 in avio_read (s=0x636d90,

buf=0x7fffffffc3e0 "o\023*J\005\214\004q\370t7P|\355y\207Y\206R\202A\365\017
_\341\016RG\037\377\020", size=6720) at libavformat/aviobuf.c:641

#6 0x00007ffff7635bbb in mpegts_read_header (s=0x626730, ap=0x7fffffffdeb0)

at libavformat/mpegts.c:1927

#7 0xd6d6d6d6d6d6d6d6 in ?? ()
#8 0xd6d6d6d6d6d6d6d6 in ?? ()
#9 0xd6d6d6d6d6d6d6d6 in ?? ()
#10 0xd6d6d6d6d6d6d6d6 in ?? ()
#11 0xd6d6d6d6d6d6d6d6 in ?? ()
#12 0xd6d6d6d6d6d6d6d6 in ?? ()
#13 0xd6d6d6d6d6d6d6d6 in ?? ()
#14 0xd6d6d6d6d6d6d6d6 in ?? ()
#15 0xd6d6d6d6d6d6d6d6 in ?? ()
#16 0xd6d6d6d6d6d6d6d6 in ?? ()
#17 0xd6d6d6d6d6d6d6d6 in ?? ()
#18 0xd6d6d6d6d6d6d6d6 in ?? ()
---Type <return> to continue, or q <return> to quit---
#19 0xd6d6d6d6d6d6d6d6 in ?? ()
#20 0xd6d6d6d6d6d6d6d6 in ?? ()
#21 0xd6d6d6d6d6d6d6d6 in ?? ()
#22 0xd6d6d6d6d6d6d6d6 in ?? ()
#23 0xd6d6d6d6d6d6d6d6 in ?? ()
#24 0xd6d6d6d6d6d6d6d6 in ?? ()
#25 0xd6d6d6d6d6d6d6d6 in ?? ()
#26 0xd6d6d6d6d6d6d6d6 in ?? ()
#27 0xd6d6d6d6d6d6d6d6 in ?? ()
#28 0xd6d6d6d6d6d6d6d6 in ?? ()
#29 0xd8902047d6d6d6d6 in ?? ()
#30 0x47ac543187e637eb in ?? ()
#31 0x026aeceb83f2f385 in ?? ()
#32 0xf814e65657150268 in ?? ()
#33 0x927d68e38a9eaae6 in ?? ()
#34 0xb7693299744a8707 in ?? ()
#35 0xc537652dbc7872f3 in ?? ()
#36 0xfd2e054e66823eeb in ?? ()
#37 0x81d31a6ef8aaa62c in ?? ()
#38 0x18c26d8e61c1ab22 in ?? ()
#39 0xe779dceae789ba2b in ?? ()
#40 0xd4ad6bf6f8c03682 in ?? ()
#41 0x1d9642cf751ccb32 in ?? ()
#42 0x31389c1040158e9b in ?? ()
#43 0xe5137802e071727c in ?? ()
#44 0x68e4b06c13206861 in ?? ()
#45 0x601f7c5d42721c98 in ?? ()
#46 0x95a4d51a0711ae53 in ?? ()
#47 0xe2b695e10f9a2e44 in ?? ()
---Type <return> to continue, or q <return> to quit---
#48 0xdef566bea4c422ec in ?? ()
#49 0x9f0fe0733e992d20 in ?? ()
#50 0x6891c636fa51a6bb in ?? ()
#51 0x13771b9fce6c651c in ?? ()
#52 0x051a552fe5f1f2d0 in ?? ()
#53 0x0505050010ff1f47 in ?? ()
#54 0x0505050505050505 in ?? ()
#55 0x0505050505050505 in ?? ()
#56 0x0505050505050505 in ?? ()
#57 0x0505050505050505 in ?? ()
#58 0x0505050505050505 in ?? ()
#59 0x0505050505050505 in ?? ()
#60 0x0505050505050505 in ?? ()
#61 0x0505050505050505 in ?? ()
#62 0x0505050505050505 in ?? ()
#63 0x0505050505050505 in ?? ()
#64 0x0505050505050505 in ?? ()
#65 0x0505050505050505 in ?? ()
#66 0x0505050505050505 in ?? ()
#67 0x0505050505050505 in ?? ()
#68 0x0505050505050505 in ?? ()
#69 0x0505050505050505 in ?? ()
#70 0x0505050505050505 in ?? ()
#71 0x0505050505050505 in ?? ()
#72 0x0505050505050505 in ?? ()
#73 0x0505050505050505 in ?? ()
#74 0x0505050505050505 in ?? ()
#75 0x0505050505050505 in ?? ()
#76 0x1310214705050505 in ?? ()
---Type <return> to continue, or q <return> to quit---
#77 0x86e28854acdba0ed in ?? ()
#78 0x68928014ef45f8f2 in ?? ()
#79 0x666c17451b5c0ac6 in ?? ()
#80 0xce4f3db7b8e1ff42 in ?? ()
#81 0xe3bc8fef61a5c15c in ?? ()
#82 0x56517371e171a725 in ?? ()
#83 0x54ffe4ca4e5198d0 in ?? ()
#84 0x2a6abf9ef27ef448 in ?? ()
#85 0xa014a0e115070da4 in ?? ()
#86 0xfd178284645cd280 in ?? ()
#87 0x02218a26893c2106 in ?? ()
#88 0xdfb8401c9ad6418c in ?? ()
#89 0x9ed53ca60adc0071 in ?? ()
#90 0x8b93c050a2d09a61 in ?? ()
#91 0x720ceac44f09b0f9 in ?? ()
#92 0xe4c7111828e01092 in ?? ()
#93 0xd1479dc5c667bf74 in ?? ()
#94 0x6e92129aa010a045 in ?? ()
#95 0x4c4cd8e6e7ee5f47 in ?? ()
#96 0x0e53ebe0a5142503 in ?? ()
#97 0x0dcbe262615905fc in ?? ()
#98 0x3b8a2e1fea2bc91f in ?? ()
#99 0x1b300890bebc0431 in ?? ()
#100 0x1b1b1b0010ff1f47 in ?? ()
#101 0x1b1b1b1b1b1b1b1b in ?? ()
#102 0x1b1b1b1b1b1b1b1b in ?? ()
#103 0x1b1b1b1b1b1b1b1b in ?? ()
#104 0x1b1b1b1b1b1b1b1b in ?? ()
#105 0x1b1b1b1b1b1b1b1b in ?? ()
---Type <return> to continue, or q <return> to quit---
#106 0x1b1b1b1b1b1b1b1b in ?? ()
#107 0x1b1b1b1b1b1b1b1b in ?? ()
#108 0x1b1b1b1b1b1b1b1b in ?? ()
#109 0x1b1b1b1b1b1b1b1b in ?? ()
#110 0x1b1b1b1b1b1b1b1b in ?? ()
#111 0x1b1b1b1b1b1b1b1b in ?? ()
#112 0x1b1b1b1b1b1b1b1b in ?? ()
#113 0x1b1b1b1b1b1b1b1b in ?? ()
#114 0x1b1b1b1b1b1b1b1b in ?? ()
#115 0x1b1b1b1b1b1b1b1b in ?? ()
#116 0x1b1b1b1b1b1b1b1b in ?? ()
#117 0x1b1b1b1b1b1b1b1b in ?? ()
#118 0x1b1b1b1b1b1b1b1b in ?? ()
#119 0x1b1b1b1b1b1b1b1b in ?? ()
#120 0x1b1b1b1b1b1b1b1b in ?? ()
#121 0x1b1b1b1b1b1b1b1b in ?? ()
#122 0x1b1b1b1b1b1b1b1b in ?? ()
#123 0xd2d020471b1b1b1b in ?? ()
#124 0xf97fca38fe0138f4 in ?? ()
#125 0xdcd6cc6779b66ea9 in ?? ()
#126 0x611ea45b78b00c11 in ?? ()
#127 0x6c11d6f610d0cd72 in ?? ()
#128 0xbaca75b875606bf4 in ?? ()
#129 0xa065c642ad3e11d6 in ?? ()
#130 0x4087f556eed230f4 in ?? ()
#131 0x205bfe6639efc313 in ?? ()
#132 0xf24976eb1aac4bed in ?? ()
#133 0xf5c0245e2d5ad1ca in ?? ()
#134 0x1869454a72af6c05 in ?? ()
---Type <return> to continue, or q <return> to quit---
#135 0xe180ccc61087d582 in ?? ()
#136 0x4a966a6fe04e909d in ?? ()
#137 0xa897385e9bad7851 in ?? ()
#138 0xbfefa3c9e1c4f9a8 in ?? ()
#139 0xd927e3df898ada23 in ?? ()
#140 0x9c4147084619cebc in ?? ()
#141 0x0dc4f8788798afb3 in ?? ()
#142 0xad86b89b0bcdf13b in ?? ()
#143 0x8faf461a5ed4ac53 in ?? ()
#144 0xbc534283367dd3f3 in ?? ()
#145 0x0376c4abbf477852 in ?? ()
#146 0x7198968b02a192f0 in ?? ()
#147 0x7171710010ff1f47 in ?? ()
#148 0x7171717171717171 in ?? ()
#149 0x7171717171717171 in ?? ()
#150 0x7171717171717171 in ?? ()
#151 0x7171717171717171 in ?? ()
#152 0x7171717171717171 in ?? ()
#153 0x7171717171717171 in ?? ()
#154 0x7171717171717171 in ?? ()
#155 0x7171717171717171 in ?? ()
#156 0x7171717171717171 in ?? ()
#157 0x7171717171717171 in ?? ()
#158 0x7171717171717171 in ?? ()
#159 0x7171717171717171 in ?? ()
#160 0x7171717171717171 in ?? ()
#161 0x7171717171717171 in ?? ()
#162 0x7171717171717171 in ?? ()
#163 0x7171717171717171 in ?? ()
---Type <return> to continue, or q <return> to quit---
#164 0x7171717171717171 in ?? ()
#165 0x7171717171717171 in ?? ()
#166 0x7171717171717171 in ?? ()
#167 0x7171717171717171 in ?? ()
#168 0x7171717171717171 in ?? ()
#169 0x7171717171717171 in ?? ()
#170 0x1311614771717171 in ?? ()
#171 0x80832202bd010000 in ?? ()
#172 0x6c645f6f85b32505 in ?? ()
#173 0xdb8690b1951a7223 in ?? ()
#174 0x000c8989e5f9c061 in ?? ()
#175 0x2b8769840828be00 in ?? ()
#176 0xf7be6930d296874b in ?? ()
#177 0x6aeebaa695340cb4 in ?? ()
#178 0x37ea4c9fa8106a6d in ?? ()
#179 0xeb016c34ad5cb167 in ?? ()
#180 0x9407ad3aeb324893 in ?? ()
#181 0xb1e6b3c2b495968b in ?? ()
#182 0x721aa105ca172b4b in ?? ()
#183 0x57df770b3c4c00b4 in ?? ()
#184 0xf1ee0773ff434010 in ?? ()
#185 0x20040101010161b0 in ?? ()
#186 0x32a9cafa20202020 in ?? ()
#187 0x9b53f98ea9abd057 in ?? ()
#188 0xea97e3467dbe7373 in ?? ()
#189 0xfd7425dfd14c3f61 in ?? ()
#190 0x4dff7ca99fd5b72a in ?? ()
#191 0x2ab5fa7c57b34fb5 in ?? ()
#192 0x156868e7f3196c6b in ?? ()
---Type <return> to continue, or q <return> to quit---
#193 0x1c8ef3975bf78466 in ?? ()
#194 0x1c1c1c0010ff1f47 in ?? ()
#195 0x1c1c1c1c1c1c1c1c in ?? ()
#196 0x1c1c1c1c1c1c1c1c in ?? ()
#197 0x1c1c1c1c1c1c1c1c in ?? ()
#198 0x1c1c1c1c1c1c1c1c in ?? ()
#199 0x1c1c1c1c1c1c1c1c in ?? ()
#200 0x1c1c1c1c1c1c1c1c in ?? ()
#201 0x1c1c1c1c1c1c1c1c in ?? ()
#202 0x1c1c1c1c1c1c1c1c in ?? ()
#203 0x1c1c1c1c1c1c1c1c in ?? ()
#204 0x1c1c1c1c1c1c1c1c in ?? ()
#205 0x1c1c1c1c1c1c1c1c in ?? ()
#206 0x1c1c1c1c1c1c1c1c in ?? ()
#207 0x1c1c1c1c1c1c1c1c in ?? ()
#208 0x1c1c1c1c1c1c1c1c in ?? ()
#209 0x1c1c1c1c1c1c1c1c in ?? ()
#210 0x1c1c1c1c1c1c1c1c in ?? ()
#211 0x1c1c1c1c1c1c1c1c in ?? ()
#212 0x1c1c1c1c1c1c1c1c in ?? ()
#213 0x1c1c1c1c1c1c1c1c in ?? ()
#214 0x1c1c1c1c1c1c1c1c in ?? ()
#215 0x1c1c1c1c1c1c1c1c in ?? ()
#216 0x1c1c1c1c1c1c1c1c in ?? ()
#217 0x10ff1f471c1c1c1c in ?? ()
#218 0x1c1c1c1c1c1c1c00 in ?? ()
#219 0x1c1c1c1c1c1c1c1c in ?? ()
#220 0x1c1c1c1c1c1c1c1c in ?? ()
#221 0x1c1c1c1c1c1c1c1c in ?? ()
---Type <return> to continue, or q <return> to quit---
#222 0x1c1c1c1c1c1c1c1c in ?? ()
#223 0x1c1c1c1c1c1c1c1c in ?? ()
#224 0x1c1c1c1c1c1c1c1c in ?? ()
#225 0x1c1c1c1c1c1c1c1c in ?? ()
#226 0x1c1c1c1c1c1c1c1c in ?? ()
#227 0x1c1c1c1c1c1c1c1c in ?? ()
#228 0x1c1c1c1c1c1c1c1c in ?? ()
#229 0x1c1c1c1c1c1c1c1c in ?? ()
#230 0x1c1c1c1c1c1c1c1c in ?? ()
#231 0x1c1c1c1c1c1c1c1c in ?? ()
#232 0x1c1c1c1c1c1c1c1c in ?? ()
#233 0x1c1c1c1c1c1c1c1c in ?? ()
#234 0x1c1c1c1c1c1c1c1c in ?? ()
#235 0x1c1c1c1c1c1c1c1c in ?? ()
#236 0x1c1c1c1c1c1c1c1c in ?? ()
#237 0x1c1c1c1c1c1c1c1c in ?? ()
#238 0x1c1c1c1c1c1c1c1c in ?? ()
#239 0x1c1c1c1c1c1c1c1c in ?? ()
#240 0x1c1c1c1c1c1c1c1c in ?? ()
#241 0x9ada8acc9b502147 in ?? ()
#242 0x710c3cd9f950efd9 in ?? ()
#243 0xda49167a0862ef6f in ?? ()
#244 0x6a48b537167ec82a in ?? ()
#245 0xf781389a95ad2206 in ?? ()
#246 0x717a35278104d937 in ?? ()
#247 0x0c9dd0ddcaf02de3 in ?? ()
#248 0x34169c209240a48a in ?? ()
#249 0x3c9ca8346a88ee7e in ?? ()
#250 0xaf7a91fa55f1f430 in ?? ()
---Type <return> to continue, or q <return> to quit---
#251 0xbb2f9ea2281f8802 in ?? ()
#252 0x6185c673601f58b0 in ?? ()
#253 0xcff1e038f6f74323 in ?? ()
#254 0x1ae1fb9530f0fcaf in ?? ()
#255 0xb87ba77da7f647f7 in ?? ()
#256 0xdefd24d3488dd40f in ?? ()
#257 0x9df56eeae635918f in ?? ()
#258 0xb7f9cdf69517367c in ?? ()
#259 0x8320636661e63c97 in ?? ()
#260 0x93aac5896e57b8c9 in ?? ()
#261 0x150939b4dae9bd1d in ?? ()
#262 0x0f3a440a5dfcfcd5 in ?? ()
#263 0x2d5b521c7543dc4c in ?? ()
#264 0xdd50204704582b6c in ?? ()
#265 0x98259a8555a63b67 in ?? ()
#266 0x59ff4101aab9fa3c in ?? ()
#267 0xb7e2a9bd7ab8f532 in ?? ()
#268 0x7099b97aa9ff0a99 in ?? ()
#269 0x426cfa2ca6ee23c6 in ?? ()
#270 0xa8f0dae660a0e1fe in ?? ()
#271 0xbdc8e068edc86484 in ?? ()
#272 0xe59a525f6e7a7a9b in ?? ()
#273 0xe85a9a5eebb513d7 in ?? ()
#274 0x289431dc55e0e6cd in ?? ()
#275 0xb0db787c4de4e076 in ?? ()
#276 0xa9f2315e4bd8b51f in ?? ()
#277 0xab58f2097e521107 in ?? ()
#278 0x057b3e14975a4704 in ?? ()
#279 0x4334fb67fd2493a6 in ?? ()
---Type <return> to continue, or q <return> to quit---
#280 0xcad01a25b034cc58 in ?? ()
#281 0xfa8b3df9367913f8 in ?? ()
#282 0x38987ea3f27232dd in ?? ()
#283 0xaef0bb20594fe908 in ?? ()
#284 0x74249a5d2617cc25 in ?? ()
#285 0xd34db055ae0dea80 in ?? ()
#286 0x83e077f7d3e42c11 in ?? ()
#287 0x60df8f29c0ed4494 in ?? ()
#288 0x6060600010ff1f47 in ?? ()
#289 0x6060606060606060 in ?? ()
#290 0x6060606060606060 in ?? ()
#291 0x6060606060606060 in ?? ()
#292 0x6060606060606060 in ?? ()
#293 0x6060606060606060 in ?? ()
#294 0x6060606060606060 in ?? ()
#295 0x6060606060606060 in ?? ()
#296 0x6060606060606060 in ?? ()
#297 0x6060606060606060 in ?? ()
#298 0x6060606060606060 in ?? ()
#299 0x6060606060606060 in ?? ()
#300 0x6060606060606060 in ?? ()
#301 0x6060606060606060 in ?? ()
#302 0x6060606060606060 in ?? ()
#303 0x6060606060606060 in ?? ()
#304 0x6060606060606060 in ?? ()
#305 0x6060606060606060 in ?? ()
#306 0x6060606060606060 in ?? ()
#307 0x6060606060606060 in ?? ()
#308 0x6060606060606060 in ?? ()
---Type <return> to continue, or q <return> to quit---
#309 0x6060606060606060 in ?? ()
#310 0x6060606060606060 in ?? ()
#311 0x1b10224760606060 in ?? ()
#312 0x61acadc61a8d8661 in ?? ()
#313 0x8661abb1b61a8d86 in ?? ()
#314 0xb61a6b3ffc8dc59a in ?? ()
#315 0xadc6da6a341a86b1 in ?? ()
#316 0x000040a8196b1a86 in ?? ()
#317 0x4dbe06eb6d1a0401 in ?? ()
#318 0x6634985940c6a023 in ?? ()
#319 0x03323d7b534e8817 in ?? ()
#320 0xa72e061314370733 in ?? ()
#321 0xbbb7cd4540dcddc6 in ?? ()
#322 0x6beec34a959fc88c in ?? ()
#323 0xc2ec4d597c56b889 in ?? ()
#324 0x83a23f7044e0223c in ?? ()
#325 0x03b6a433d1d1ac46 in ?? ()
#326 0x21df16ef6a2da6ed in ?? ()
#327 0x0d33f8640319716f in ?? ()
#328 0x7f22b827a4662438 in ?? ()
#329 0xd132c42b4d14a4da in ?? ()
#330 0x1bb70f66a07ee0da in ?? ()
#331 0x3059f4d313f2098e in ?? ()
#332 0x931957714369d1bc in ?? ()
#333 0xad76754b4ec6191a in ?? ()
#334 0xf7520935681ff8d3 in ?? ()
#335 0xf7f7f70010ff1f47 in ?? ()
#336 0xf7f7f7f7f7f7f7f7 in ?? ()
#337 0xf7f7f7f7f7f7f7f7 in ?? ()
---Type <return> to continue, or q <return> to quit---
#338 0xf7f7f7f7f7f7f7f7 in ?? ()
#339 0xf7f7f7f7f7f7f7f7 in ?? ()
#340 0xf7f7f7f7f7f7f7f7 in ?? ()
#341 0xf7f7f7f7f7f7f7f7 in ?? ()
#342 0xf7f7f7f7f7f7f7f7 in ?? ()
#343 0xf7f7f7f7f7f7f7f7 in ?? ()
#344 0xf7f7f7f7f7f7f7f7 in ?? ()
#345 0xf7f7f7f7f7f7f7f7 in ?? ()
#346 0xf7f7f7f7f7f7f7f7 in ?? ()
#347 0xf7f7f7f7f7f7f7f7 in ?? ()
#348 0xf7f7f7f7f7f7f7f7 in ?? ()
#349 0xf7f7f7f7f7f7f7f7 in ?? ()
#350 0xf7f7f7f7f7f7f7f7 in ?? ()
#351 0xf7f7f7f7f7f7f7f7 in ?? ()
#352 0xf7f7f7f7f7f7f7f7 in ?? ()
#353 0xf7f7f7f7f7f7f7f7 in ?? ()
#354 0xf7f7f7f7f7f7f7f7 in ?? ()
#355 0xf7f7f7f7f7f7f7f7 in ?? ()
#356 0xf7f7f7f7f7f7f7f7 in ?? ()
#357 0xf7f7f7f7f7f7f7f7 in ?? ()
#358 0xd6d02147f7f7f7f7 in ?? ()
#359 0xd1478fbb95c67dad in ?? ()
#360 0x0e52dc76944488e2 in ?? ()
#361 0x9b605c8d8878e0fd in ?? ()
#362 0x1079eaf0aee1fb4f in ?? ()
#363 0xbe4fbcb47017e4df in ?? ()
#364 0xa7ea3780816ab605 in ?? ()
#365 0xbec5ae2a9bc50fe5 in ?? ()
#366 0xdfbe58ef2c3ffd0d in ?? ()
---Type <return> to continue, or q <return> to quit---
#367 0x19bb87f765c86e4d in ?? ()
#368 0x6a6bb28dc1c985b4 in ?? ()
#369 0x7079d9c66aae860e in ?? ()
#370 0xda3c0edda6069cca in ?? ()
#371 0x100b22437adcb605 in ?? ()
#372 0xb32e0e7fe4114421 in ?? ()
#373 0xcbc808a07561c5fc in ?? ()
#374 0x65cbf302fbce9947 in ?? ()
#375 0x61347f6f33d42003 in ?? ()
#376 0xea7b1ec961f7e130 in ?? ()
#377 0xf4e7e231e82fb334 in ?? ()
#378 0xcbacbada118416e0 in ?? ()
#379 0xfbd22b54c65006ab in ?? ()
#380 0xbabb974785fb088b in ?? ()
#381 0x226ae75a99912061 in ?? ()
#382 0x2222220010ff1f47 in ?? ()
#383 0x2222222222222222 in ?? ()
#384 0x2222222222222222 in ?? ()
#385 0x2222222222222222 in ?? ()
#386 0x2222222222222222 in ?? ()
#387 0x2222222222222222 in ?? ()
#388 0x2222222222222222 in ?? ()
#389 0x2222222222222222 in ?? ()
#390 0x2222222222222222 in ?? ()
#391 0x2222222222222222 in ?? ()
#392 0x2222222222222222 in ?? ()
#393 0x2222222222222222 in ?? ()
#394 0x2222222222222222 in ?? ()
#395 0x2222222222222222 in ?? ()
---Type <return> to continue, or q <return> to quit---
#396 0x2222222222222222 in ?? ()
#397 0x2222222222222222 in ?? ()
#398 0x2222222222222222 in ?? ()
#399 0x2222222222222222 in ?? ()
#400 0x2222222222222222 in ?? ()
#401 0x2222222222222222 in ?? ()
#402 0x2222222222222222 in ?? ()
#403 0x2222222222222222 in ?? ()
#404 0x2222222222222222 in ?? ()
#405 0xda12204722222222 in ?? ()
#406 0xb3b6f29290d73f72 in ?? ()
#407 0xd1707f0f5f9a87a5 in ?? ()
#408 0xaf322e5c90bc70c2 in ?? ()
#409 0x1c4ca2379b9772c1 in ?? ()
#410 0xe2b9cf789c7ef42e in ?? ()
#411 0xc9040f7455840f50 in ?? ()
#412 0x844cb8939d59e2f5 in ?? ()
#413 0x75cddd52e9864b94 in ?? ()
#414 0x6b8d89be488d6b91 in ?? ()
#415 0x15931adbb271a865 in ?? ()
#416 0xf06d12976b8574af in ?? ()
#417 0x8152d06e2539c67b in ?? ()
#418 0xb11ff9c79de570ba in ?? ()
#419 0xb509f62cc372e7c3 in ?? ()
#420 0x1599a09bcc5a9004 in ?? ()
#421 0x472c4f711ad19230 in ?? ()
#422 0x15a8c146b65101ad in ?? ()
#423 0x2230f67fddf4b8f3 in ?? ()
#424 0xae1cc4813ff30636 in ?? ()
---Type <return> to continue, or q <return> to quit---
#425 0x1c49281a0825e4d2 in ?? ()
#426 0x54c9a693befda648 in ?? ()
#427 0xacd30be2f697b843 in ?? ()
#428 0xf5948bfc0f9d2722 in ?? ()
#429 0xf5f5f50010ff1f47 in ?? ()
#430 0xf5f5f5f5f5f5f5f5 in ?? ()
#431 0xf5f5f5f5f5f5f5f5 in ?? ()
#432 0xf5f5f5f5f5f5f5f5 in ?? ()
#433 0xf5f5f5f5f5f5f5f5 in ?? ()
#434 0xf5f5f5f5f5f5f5f5 in ?? ()
#435 0xf5f5f5f5f5f5f5f5 in ?? ()
#436 0xf5f5f5f5f5f5f5f5 in ?? ()
#437 0xf5f5f5f5f5f5f5f5 in ?? ()
#438 0xf5f5f5f5f5f5f5f5 in ?? ()
#439 0xf5f5f5f5f5f5f5f5 in ?? ()
#440 0xf5f5f5f5f5f5f5f5 in ?? ()
#441 0xf5f5f5f5f5f5f5f5 in ?? ()
#442 0xf5f5f5f5f5f5f5f5 in ?? ()
#443 0xf5f5f5f5f5f5f5f5 in ?? ()
#444 0xf5f5f5f5f5f5f5f5 in ?? ()
#445 0xf5f5f5f5f5f5f5f5 in ?? ()
#446 0xf5f5f5f5f5f5f5f5 in ?? ()
#447 0xf5f5f5f5f5f5f5f5 in ?? ()
#448 0xf5f5f5f5f5f5f5f5 in ?? ()
#449 0xf5f5f5f5f5f5f5f5 in ?? ()
#450 0xf5f5f5f5f5f5f5f5 in ?? ()
#451 0xf5f5f5f5f5f5f5f5 in ?? ()
#452 0xd9902047f5f5f5f5 in ?? ()
#453 0xe8de1832b796d54c in ?? ()
---Type <return> to continue, or q <return> to quit---
#454 0x6d96be966e055e66 in ?? ()
#455 0x244f5c69031b1737 in ?? ()
#456 0xecdfe8a6f13f4101 in ?? ()
#457 0x23519d4286ff513d in ?? ()
#458 0x6006e29adf91e059 in ?? ()
#459 0x39a727cb7fa5039b in ?? ()
#460 0xaf1a04b7ce3b9b54 in ?? ()
#461 0x5571fcef7f973d90 in ?? ()
#462 0xda00ee4fbb35d66d in ?? ()
#463 0xe8b0970637064e64 in ?? ()
#464 0xe9b8694f42fea1f5 in ?? ()
#465 0xcd0c5a698e4a9d29 in ?? ()
#466 0x8ee679dca5f1cbe3 in ?? ()
#467 0x0cd244e178e80b06 in ?? ()
#468 0xf540f37030eeb64c in ?? ()
#469 0x0ffbf08805829951 in ?? ()
#470 0x5e8f273cb38713cc in ?? ()
#471 0x968a006149194bb0 in ?? ()
#472 0x2af4cfebc49843f3 in ?? ()
#473 0x1229a9bd3ca9f9b0 in ?? ()
#474 0x83add1ec7c648e88 in ?? ()
#475 0x0855f0e6071c72be in ?? ()
#476 0x0808080010ff1f47 in ?? ()
#477 0x0808080808080808 in ?? ()
#478 0x0808080808080808 in ?? ()
#479 0x0808080808080808 in ?? ()
#480 0x0808080808080808 in ?? ()
#481 0x0808080808080808 in ?? ()
#482 0x0808080808080808 in ?? ()
---Type <return> to continue, or q <return> to quit---
#483 0x0808080808080808 in ?? ()
#484 0x0808080808080808 in ?? ()
#485 0x0808080808080808 in ?? ()
#486 0x0808080808080808 in ?? ()
#487 0x0808080808080808 in ?? ()
#488 0x0808080808080808 in ?? ()
#489 0x0808080808080808 in ?? ()
#490 0x0808080808080808 in ?? ()
#491 0x0808080808080808 in ?? ()
#492 0x0808080808080808 in ?? ()
#493 0x0808080808080808 in ?? ()
#494 0x0808080808080808 in ?? ()
#495 0x0808080808080808 in ?? ()
#496 0x0808080808080808 in ?? ()
#497 0x0808080808080808 in ?? ()
#498 0x0808080808080808 in ?? ()
#499 0x1410214708080808 in ?? ()
#500 0x546135fe946c94ad in ?? ()
#501 0x9b09014b143dd5f2 in ?? ()
#502 0x0a0e7083e6a8a4b0 in ?? ()
#503 0x2e50017d04be14ca in ?? ()
#504 0xa0c44009a5254851 in ?? ()
#505 0x6c6c6ea8bbf16f6e in ?? ()
#506 0x9ab3e7ce8d111cb6 in ?? ()
#507 0x298a367e03ca8b76 in ?? ()
#508 0x81b88bcbd0490781 in ?? ()
#509 0x75a6944784b19c98 in ?? ()
#510 0xa2a768963493cf63 in ?? ()
#511 0x07cffeda8c39cc8b in ?? ()
---Type <return> to continue, or q <return> to quit---
#512 0x61025214b59e6eb4 in ?? ()
#513 0x1e67add918c639c0 in ?? ()
#514 0x180cf4212a65cce3 in ?? ()
#515 0x2b9080a575e09cf8 in ?? ()
#516 0x712f01ad50b1acfe in ?? ()
#517 0x4811fbd0bf0ecc82 in ?? ()
#518 0x2e346c10e0b133cd in ?? ()
#519 0xca5df8c520b7292f in ?? ()
#520 0xbeab8819319b1553 in ?? ()
#521 0x3a0392eb44dd94b6 in ?? ()
#522 0xa459e1838901e23a in ?? ()
#523 0xa4a4a40010ff1f47 in ?? ()
#524 0xa4a4a4a4a4a4a4a4 in ?? ()
#525 0xa4a4a4a4a4a4a4a4 in ?? ()
#526 0xa4a4a4a4a4a4a4a4 in ?? ()
#527 0xa4a4a4a4a4a4a4a4 in ?? ()
#528 0xa4a4a4a4a4a4a4a4 in ?? ()
#529 0xa4a4a4a4a4a4a4a4 in ?? ()
#530 0xa4a4a4a4a4a4a4a4 in ?? ()
#531 0xa4a4a4a4a4a4a4a4 in ?? ()
#532 0xa4a4a4a4a4a4a4a4 in ?? ()
#533 0xa4a4a4a4a4a4a4a4 in ?? ()
#534 0xa4a4a4a4a4a4a4a4 in ?? ()
#535 0xa4a4a4a4a4a4a4a4 in ?? ()
#536 0xa4a4a4a4a4a4a4a4 in ?? ()
#537 0xa4a4a4a4a4a4a4a4 in ?? ()
#538 0xa4a4a4a4a4a4a4a4 in ?? ()
#539 0xa4a4a4a4a4a4a4a4 in ?? ()
#540 0xa4a4a4a4a4a4a4a4 in ?? ()
---Type <return> to continue, or q <return> to quit---
#541 0xa4a4a4a4a4a4a4a4 in ?? ()
#542 0xa4a4a4a4a4a4a4a4 in ?? ()
#543 0xa4a4a4a4a4a4a4a4 in ?? ()
#544 0xa4a4a4a4a4a4a4a4 in ?? ()
#545 0xa4a4a4a4a4a4a4a4 in ?? ()
#546 0x9c502147a4a4a4a4 in ?? ()
#547 0x7e488e8bfb1ba140 in ?? ()
#548 0x0723eb63086bd90e in ?? ()
#549 0xc7eb1d54a400b5be in ?? ()
#550 0x4757814811bf2a37 in ?? ()
#551 0xa7c8e210b3a41dbe in ?? ()
#552 0xe8b66d891301df95 in ?? ()
#553 0x25937e9d253ce68a in ?? ()
#554 0xe3264f6ac85092a8 in ?? ()
#555 0x09599078b4bb7dfb in ?? ()
#556 0x49d2e7b306d18451 in ?? ()
#557 0x7769446ce3ebcad9 in ?? ()
#558 0xc2c5ff2cfd9ca814 in ?? ()
#559 0x3b30dd0d0d160d19 in ?? ()
#560 0xd91d31d462d13474 in ?? ()
#561 0x226e2cf33f856e40 in ?? ()
#562 0x23094ce4601f3547 in ?? ()
#563 0x28df853dd122d748 in ?? ()
#564 0xacc0cca594c9b610 in ?? ()
#565 0x2764b217b1101d42 in ?? ()
#566 0x4e54f1f1851bd861 in ?? ()
#567 0xc078a405a15be1fc in ?? ()
Cannot access memory at address 0x7ffffffff000
(gdb)
(gdb) disass $pc-32,$pc+32
Dump of assembler code from 0x7ffff57ed21b to 0x7ffff57ed25b:

0x00007ffff57ed21b <memcpy+315>: (bad)
0x00007ffff57ed21c <memcpy+316>: (bad)
0x00007ffff57ed21d <memcpy+317>: push %rbx
0x00007ffff57ed21f <memcpy+319>: retq
0x00007ffff57ed220 <memcpy+320>: mov 0x2d1ec9(%rip),%r11 # 0x7ffff5abf0f0 <x86_64_data_cache_size_half>
0x00007ffff57ed227 <memcpy+327>: cmp %rdx,%r11
0x00007ffff57ed22a <memcpy+330>: cmova %rdx,%r11
0x00007ffff57ed22e <memcpy+334>: mov %r11,%rcx
0x00007ffff57ed231 <memcpy+337>: and $0xfffffffffffffff8,%r11
0x00007ffff57ed235 <memcpy+341>: shr $0x3,%rcx
0x00007ffff57ed239 <memcpy+345>: je 0x7ffff57ed240 <memcpy+352>

=> 0x00007ffff57ed23b <memcpy+347>: rep movsq %ds:(%rsi),%es:(%rdi)

0x00007ffff57ed23e <memcpy+350>: xchg %ax,%ax
0x00007ffff57ed240 <memcpy+352>: sub %r11,%rdx
0x00007ffff57ed243 <memcpy+355>: test $0xfffffffffffffff8,%rdx
0x00007ffff57ed24a <memcpy+362>: jne 0x7ffff57ed260 <memcpy+384>
0x00007ffff57ed24c <memcpy+364>: and $0x7,%edx
0x00007ffff57ed24f <memcpy+367>: mov -0x8(%rsp),%rax
0x00007ffff57ed254 <memcpy+372>: jne 0x7ffff57ed0e9 <memcpy+9>
0x00007ffff57ed25a <memcpy+378>: repz retq

End of assembler dump.
(gdb) info all-registers
rax 0x7fffffffc3e0 140737488339936
rbx 0x7fffffffc3e0 140737488339936
rcx 0x27c 636
rdx 0xfffffffff2bf1824 -222357468
rsi 0x7ffff38da1f8 140737279533560
rdi 0x7ffffffff000 140737488351232
rbp 0x7fffffffbb20 0x7fffffffbb20
rsp 0x7fffffffbad8 0x7fffffffbad8
r8 0x7ffff769843e 140737344275518
r9 0x7ffff7fe4700 140737354024704
r10 0x0 0
r11 0x4000 16384
r12 0x405480 4215936
r13 0x7fffffffe410 140737488348176
r14 0x0 0
r15 0x0 0
rip 0x7ffff57ed23b 0x7ffff57ed23b <memcpy+347>
eflags 0x10206 [ PF IF RF ]
cs 0x33 51
ss 0x2b 43
ds 0x0 0
es 0x0 0
fs 0x0 0
gs 0x0 0
st0 0 (raw 0x00000000000000000000)
st1 0 (raw 0x00000000000000000000)
st2 0 (raw 0x00000000000000000000)
st3 0 (raw 0x00000000000000000000)
st4 0 (raw 0x00000000000000000000)
---Type <return> to continue, or q <return> to quit---
st5 0 (raw 0x00000000000000000000)
st6 0 (raw 0x00000000000000000000)
st7 0 (raw 0x00000000000000000000)
fctrl 0x37f 895
fstat 0x0 0
ftag 0xffff 65535
fiseg 0x0 0
fioff 0x0 0
foseg 0x0 0
fooff 0x0 0
fop 0x0 0
xmm0 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x8000000000000000, 0x8000000000000000},

v16_int8 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0xff, 0xff, 0x0, 0xff, 0xff, 0xff, 0xff, 0xff},
v8_int16 = {0x0, 0x0, 0x0, 0xff00, 0xffff, 0xff00, 0xffff, 0xffff}, v4_int32 = {0x0, 0xff000000,

0xff00ffff, 0xffffffff}, v2_int64 = {0xff00000000000000, 0xffffffffff00ffff},

uint128 = 0xffffffffff00ffffff00000000000000}

xmm1 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm2 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm3 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {0x0, 0x0, 0x0,

0x0, 0xff, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xff, 0x0}, v8_int16 = {0x0, 0x0, 0xff,
0x0, 0x0, 0x0, 0x0, 0xff}, v4_int32 = {0x0, 0xff, 0x0, 0xff0000}, v2_int64 = {0xff00000000,
0xff000000000000}, uint128 = 0x00ff000000000000000000ff00000000}

xmm4 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {0x75, 0x1, 0x0,

0x0, 0x1, 0x0, 0x0, 0x0, 0xa, 0x87, 0xde, 0xf7, 0xff, 0x7f, 0x0, 0x0}, v8_int16 = {0x175, 0x0, 0x1,
0x0, 0x870a, 0xf7de, 0x7fff, 0x0}, v4_int32 = {0x175, 0x1, 0xf7de870a, 0x7fff}, v2_int64 = {

---Type <return> to continue, or q <return> to quit---

0x100000175, 0x7ffff7de870a}, uint128 = 0x00007ffff7de870a0000000100000175}

xmm5 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm6 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm7 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm8 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm9 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm10 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm11 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm12 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm13 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm14 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {
---Type <return> to continue, or q <return> to quit---

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

xmm15 {v4_float = {0x0, 0x0, 0x0, 0x0}, v2_double = {0x0, 0x0}, v16_int8 = {

0x0 <repeats 16 times>}, v8_int16 = {0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0}, v4_int32 = {0x0, 0x0,
0x0, 0x0}, v2_int64 = {0x0, 0x0}, uint128 = 0x00000000000000000000000000000000}

mxcsr 0x1f80 [ IM DM ZM OM UM PM ]
(gdb)

There is my fix against git master HEAD 988f585fcb1cfb40fe4b706c32b31594b536bba0

From 6d81d553bb75d3ed9d6a13f00fe21bf1f0474eb5 Mon Sep 17 00:00:00 2001
From: Andrey Utkin <andrey.krieger.utkin@gmail.com>
Date: Thu, 3 Nov 2011 07:00:15 +0000
Subject: [PATCH] Fix segfault on UDP reading

---

libavformat/udp.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/libavformat/udp.c b/libavformat/udp.c
index 151e070..59d1f74 100644
--- a/libavformat/udp.c
+++ b/libavformat/udp.c
@@ -546,15 +546,19 @@ static int udp_read(URLContext *h, uint8_t *buf, int size)

avail = av_fifo_size(s->fifo);
if (avail) { >=size) {

uint8_t tmp[4];

+ int skip = 0;

av_fifo_generic_read(s->fifo, tmp, 4, NULL);
avail= AV_RL32(tmp);
if(avail > size){

av_log(h, AV_LOG_WARNING, "Part of datagram lost due to insufficient buffer size\n");

+ skip = avail - size;

avail= size;

}


av_fifo_generic_read(s->fifo, buf, avail, NULL);

+ if (skip)
+ av_fifo_drain(s->fifo, skip);

return avail;

}
else {

--
1.7.3.4

Attachments (2)

test.ts (1.0 MB) - added by Krieger 5 years ago.
Test media
0001-Fix-segfault-on-UDP-reading.patch (1.2 KB) - added by Krieger 5 years ago.
Git patch

Download all attachments as: .zip

Change History (4)

Changed 5 years ago by Krieger

Test media

Changed 5 years ago by Krieger

Git patch

comment:1 Changed 5 years ago by cehoyos

Please recompile without --enable-shared to get a useful backtrace (and please use "Code block" when pasting gdb output).

comment:2 Changed 5 years ago by michael

  • Resolution set to fixed
  • Status changed from new to closed

Patch applied and simplified
Thanks alot!

Note: See TracTickets for help on using tickets.