[Xvid-devel] 1.3.5 segfault in check_cpu_features (xvidcore/src/utils/x86_asm/cpuid.asm:97)

Peter Ross pross at xvid.org
Thu Jan 17 11:09:49 CET 2019


On Wed, Jan 16, 2019 at 02:23:05PM +0000, Michael Militzer wrote:
> Hi,
> 
> does this crash happen also outside of ffmpeg, so e.g. when you run  
> the xvid_encraw example?

Repost:

this problem is caused by our use of .rotext. changing it to .text works.
patch below.

i do not believe binutils recognises .rotext as a machine instruction section anyway.
obdump -d does not work on such files. cheers,


Patch:

[PATCH] alway use .text for machine
---
 src/nasm.inc | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/src/nasm.inc b/src/nasm.inc
index e5181c9..f79efe6 100644
--- a/src/nasm.inc
+++ b/src/nasm.inc
@@ -175,15 +175,7 @@ BITS 32
 %endmacro

 %macro TEXT 0
-%ifidn __OUTPUT_FORMAT__,macho32
       SECTION .text align=SECTION_ALIGN
-%else
-%ifidn __OUTPUT_FORMAT__,macho64
-      SECTION .text align=SECTION_ALIGN
-%else
-      SECTION .rotext align=SECTION_ALIGN
-%endif
-%endif
 %endmacro

 %macro cglobal 1
--
2.17.1

-- Peter
(A907 E02F A6E5 0CD2 34CD 20D2 6760 79C5 AC40 DD6B)


More information about the Xvid-devel mailing list