Re: unsafe printing
Re: unsafe printing
- Subject: Re: unsafe printing
- From: Kyle Sluder <email@hidden>
- Date: Mon, 13 Jul 2015 14:56:17 -0500
On Fri, Jul 10, 2015, at 02:57 PM, Jan E. Schotsman wrote:
> Hello,
>
> How can I get rid of warnings about unsafe use of printf?
>
> char myString[256];
>
> // set myString in some untransparent way
>
> printf( myString ); // warning: format string is not a literal
> (potentially insecure)
Use printf("%s", myString).
--Kyle Sluder
>
> Xcode 6.3
>
> TIA,
>
> Jan E.
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Xcode-users mailing list (email@hidden)
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden