a044a183a3 
								
							
								 
							
						 
						
							
							
								
								avutil/log: skip IO calls on empty strings  
							
							These occur when no context is set for example, thus they are common
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								d6838309fe 
								
							
								 
							
						 
						
							
							
								
								avutil/log: skip setting color for default (AV_LOG_INFO) level  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								2c21e2ee4c 
								
							
								 
							
						 
						
							
							
								
								avutil/log: merge calls that set ansi color and print the string  
							
							about 1/3 or so faster
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								808c10e728 
								
							
								 
							
						 
						
							
							
								
								avutil/log: check that len is within the buffer before reading it  
							
							Fixes out of array read
Fixes: asan_heap-oob_19d6979_6857_mmw_deadzy.ogg
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								423ae31354 
								
							
								 
							
						 
						
							
							
								
								avutil/log: make default av_log callback thread safe  
							
							This uses a pthread mutex
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								3ed65d98c6 
								
							
								 
							
						 
						
							
							
								
								avutil/log: fix race between setting and using the log callback  
							
							Found-by: wm4
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								148310ca16 
								
							
								 
							
						 
						
							
							
								
								avutil/log: Use bprint for part  
							
							This should fix the issue with strings longer than 1024
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								39bb26f91b 
								
							
								 
							
						 
						
							
							
								
								lavu/log: do not skip overwritten lines.  
							
							If the line ends with \r, it will not flood the tty, and
the "Last message repeated" line would overwrite it.
Fix bug introduced by c25d1ba 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								c25d1ba556 
								
							
								 
							
						 
						
							
							
								
								lavu/log: print prefix after \r.  
							
							Should fix trac ticket #2797  because of the progress line. 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								0420c810ce 
								
							
								 
							
						 
						
							
							
								
								log: pass the correct parameters to missing_feature_sample  
							
							CC:libav-stable@libav.org 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								7edb984dd0 
								
							
								 
							
						 
						
							
							
								
								avutil/log: Fix context pointer used for get_category()  
							
							Fixes calling a random pointer
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								a057552212 
								
							
								 
							
						 
						
							
							
								
								avutil/log: dont count&print repeats for empty strings  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								74b1c32a80 
								
							
								 
							
						 
						
							
							
								
								avutil/log: leave prefix printing state on empty input.  
							
							Fixes printing the prefix after an empty string was printed
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								572e38a513 
								
							
								 
							
						 
						
							
							
								
								log: Remove redundant va_list creation from missing_feature_sample()  
							
							avpriv_request_sample() and avpriv_report_missing_feature() were printing bogus values for the extra arguments.
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								f099d3d1d5 
								
							
								 
							
						 
						
							
							
								
								Add av_log_{ask_for_sample|missing_feature} replacements to libavutil  
							
							This allows reporting missing features and requesting samples from
all libraries in a standard way; with a simplified API. 
							
						 
						12 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								cb45553f57 
								
							
								 
							
						 
						
							
							
								
								Remove pointless #undefs of previously forbidden functions.  
							
							
								
							
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								7e6a11bcf7 
								
							
								 
							
						 
						
							
							
								
								avutil: Use a configure check to enable windows console functions  
							
							Not all versions or API subsets of windows have these functions.
Signed-off-by: Martin Storsjö <martin@martin.st> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								b70abd5b61 
								
							
								 
							
						 
						
							
							
								
								avutil: Include io.h with a separate condition from windows console functions  
							
							Not all versions of windows have the console color functions,
while io.h might be needed for isatty (which can be found in
unistd.h or io.h).
Signed-off-by: Martin Storsjö <martin@martin.st> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								1d9c2dc89a 
								
							
								 
							
						 
						
							
							
								
								Don't include common.h from avutil.h  
							
							Signed-off-by: Martin Storsjö <martin@martin.st> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								50bfd547b9 
								
							
								 
							
						 
						
							
							
								
								log: fix compilation failure on mingw due to reference to undefined set_color256  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								1842b27564 
								
							
								 
							
						 
						
							
							
								
								lavu: 256 color support  
							
							Signed-off-by: Paul B Mahol <onemda@gmail.com> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								ee7214c59a 
								
							
								 
							
						 
						
							
							
								
								log: change color for filters from blue to bright green  
							
							The blue is difficult to read on several peoples terminals with black background.
Idea-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								246154a9af 
								
							
								 
							
						 
						
							
							
								
								log: Include io.h on windows  
							
							This is required for isatty, which exists on MSVC and is found by
configure, but is provided by io.h instead of unistd.h.
Signed-off-by: Martin Storsjö <martin@martin.st> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								145a8096d5 
								
							
								 
							
						 
						
							
							
								
								log: Only include unistd.h if configure found it  
							
							MSVC has isatty (in io.h), but not unistd.h. (isatty isn't called
at all for windows, since there's a special case block for that.)
Signed-off-by: Martin Storsjö <martin@martin.st> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								258dfff839 
								
							
								 
							
						 
						
							
							
								
								extend log line buffer sizes  
							
							The string passed to av_vlog() from libx264's X264_log overflows the 512
byte part_size, truncating x264 parameter output.  Double this size
and put it in a #define so it only needs to be changed in one place.
Signed-off-by: Wolfram Gloger <video06@malloc.de>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								539df61193 
								
							
								 
							
						 
						
							
							
								
								log: include unistd.h only when needed  
							
							The only symbol this file uses from unistd.h is isatty().  By
including the header only when this function is used, the file
can be built on systems without unistd.h (which presumably also
lack isatty).
Signed-off-by: Mans Rullgard <mans@mansr.com> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								bc210bfca6 
								
							
								 
							
						 
						
							
							
								
								log: flip highlight bit for codec & muxer layer  
							
							This way the encoder/muxer side is bold
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								e69263cd01 
								
							
								 
							
						 
						
							
							
								
								avutil: add get_category() for the case where one AVClass can have more than 1 category  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								b76f77ee0d 
								
							
								 
							
						 
						
							
							
								
								log: swap colors for muxer and codec layer  
							
							This way the filters which are semantically closer to the codec layer
have a (subjectively to me) more similar color.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								eb7efc126a 
								
							
								 
							
						 
						
							
							
								
								log: color prefixes according to their source.  
							
							The use of cyan is droped from the levels to avoid confusion
magenta/cyan/blue is used for muxer/codec/filter layer
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								2191aef93b 
								
							
								 
							
						 
						
							
							
								
								log: cleanup color arrays  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								780ff97fef 
								
							
								 
							
						 
						
							
							
								
								log: make colored output more colorful.  
							
							Green for verbose, cyan for debug. 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								7c7c5b2415 
								
							
								 
							
						 
						
							
							
								
								avutil/log: allow av_log_set_callback (NULL)  
							
							Idea-by: Don Moir <donmoir@comcast.net>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						13 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								625751c47a 
								
							
								 
							
						 
						
							
							
								
								log: use a different color for debug (green).  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								26c6fec9d9 
								
							
								 
							
						 
						
							
							
								
								lavu: introduce av_log_format_line.  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								425b45d4b0 
								
							
								 
							
						 
						
							
							
								
								Code clean-up for crc.c, lfg.c, log.c, random_see.d, rational.c and tree.c.  
							
							Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com> 
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								f36b390275 
								
							
								 
							
						 
						
							
							
								
								Replace some forgotten FFmpeg references by Libav.  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								847aaec682 
								
							
								 
							
						 
						
							
							
								
								log: Fix an oob array read.  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								1a5e4fd8c5 
								
							
								 
							
						 
						
							
							
								
								Replace strncpy() with av_strlcpy().  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								0247bdee25 
								
							
								 
							
						 
						
							
							
								
								Fix races in default av_log handler  
							
							Prevent competing threads from overwriting (shared) buffers.
Original patch by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								63de9e7d80 
								
							
								 
							
						 
						
							
							
								
								Remove a version check in av_log made unnecessary by the big bump.  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								490a022d86 
								
							
								 
							
						 
						
							
							
								
								lavu: remove misc disabled cruft  
							
							
								
							
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								48ee302e0f 
								
							
								 
							
						 
						
							
							
								
								Fix apparently exploitable race condition.  
							
							Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								0a51362b3f 
								
							
								 
							
						 
						
							
							
								
								log:Sanitize string of most control chars before printing.  
							
							This may be security relevant depending upon the used terminal.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at> 
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								2912e87a6c 
								
							
								 
							
						 
						
							
							
								
								Replace FFmpeg with Libav in licence headers  
							
							Signed-off-by: Mans Rullgard <mans@mansr.com> 
							
						 
						14 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								dfaa9f3cb3 
								
							
								 
							
						 
						
							
							
								
								Recognize FFMPEG_FORCE_NOCOLOR environment variable on Win32  
							
							Fixes issue 2461
Originally committed as revision 26186 to svn://svn.ffmpeg.org/ffmpeg/trunk 
							
						 
						15 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								3011ecdeb7 
								
							
								 
							
						 
						
							
							
								
								Introduce FFMPEG_FORCE_NOCOLOR, with the same meaning and use of  
							
							NO_COLOR (but properly prefixed for avoiding namespace conflicts).
Originally committed as revision 25899 to svn://svn.ffmpeg.org/ffmpeg/trunk 
							
						 
						15 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								129983408d 
								
							
								 
							
						 
						
							
							
								
								Allow to force colored output.  
							
							Patch by Etienne Buira, etienne d buira d lists a free d fr
Originally committed as revision 25888 to svn://svn.ffmpeg.org/ffmpeg/trunk 
							
						 
						15 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								d7cd001ff2 
								
							
								 
							
						 
						
							
							
								
								indent  
							
							Originally committed as revision 25178 to svn://svn.ffmpeg.org/ffmpeg/trunk 
							
						 
						15 years ago  
				
					
						
							
							
								 
						
							
							
							
								
							
								8a19053361 
								
							
								 
							
						 
						
							
							
								
								Cosmetic (rename detect_repeats to is_atty which matches the truth)  
							
							Originally committed as revision 25177 to svn://svn.ffmpeg.org/ffmpeg/trunk 
							
						 
						15 years ago