[Live-devel] compilation issue / vcpkg / windows

g.jaegy g.jaegy at imagine3d.fr
Fri Feb 4 02:46:13 PST 2022


OK. Possibly one could also fix the error by using alloca(), possibly leading to the same result ?

I'm using Visual Studio 2022 and can't really update.

-----Original Message-----
From: live-devel <live-devel-bounces at us.live555.com> On Behalf Of Ross Finlayson
Sent: Friday, February 4, 2022 11:28 AM
To: LIVE555 Streaming Media - development & use <live-devel at us.live555.com>
Subject: Re: [Live-devel] compilation issue / vcpkg / windows



> On Feb 4, 2022, at 10:58 PM, g.jaegy <g.jaegy at imagine3d.fr> wrote:
> 
> Upstream accidentally stepped on trying to use C99 VLAs; fOutBuf->curPacketSize() is not a constant.
> 
> 	// Hack: Because the MKI + authentication tag at the end of the packet would
> 	// overwrite any following (still to be sent) frame data, we can't encrypt/tag
> 	// the packet in place.  Instead, we have to make a copy (on the stack) of
> 	// the packet, before encrypting/tagging/sending it:
> 	u_int8_t packet[fOutBuf->curPacketSize() + SRTP_MKI_LENGTH + SRTP_AUTH_TAG_LENGTH];
> 	memcpy(packet, fOutBuf->packet(), fOutBuf->curPacketSize());
> 	unsigned newPacketSize;

It seems that you’re using a C++ compiler that doesn’t handle variable-sized data being allocated on the stack.  If you can’t upgrade your compiler, then you will be able to compile it by adding 
	-DNO_OPENSSL=1
to your compile flags.  (Of course, if you do this, then you won’t be able to handle connections over TLS, or SRTP.)


Ross Finlayson
Live Networks, Inc.
http://www.live555.com/


_______________________________________________
live-devel mailing list
live-devel at lists.live555.com
http://lists.live555.com/mailman/listinfo/live-devel



More information about the live-devel mailing list