printf Bug
#3

Quote:
Originally Posted by Vince
Посмотреть сообщение
No, you're just overwriting the null terminator. Thus the compiler can't tell where the string ends and pops out.
Not the compiler. The printf function looks for the terminator, but as OP did not include it, it will read onto into the memory next to it. This produces the unexpected results. But to be clear: this is a runtime error, not a compiler error.
Reply


Messages In This Thread
printf Bug - by Kaliber - 06.10.2014, 13:10
Re: printf Bug - by Vince - 06.10.2014, 13:37
Re: printf Bug - by IJzerenRita - 06.10.2014, 13:41
Re: printf Bug - by KingHual - 06.10.2014, 13:48
AW: Re: printf Bug - by Kaliber - 06.10.2014, 13:55
Re: printf Bug - by Vince - 06.10.2014, 13:57
AW: Re: printf Bug - by Kaliber - 06.10.2014, 13:58
Re: AW: Re: printf Bug - by KingHual - 06.10.2014, 13:58
Re: AW: Re: printf Bug - by IJzerenRita - 06.10.2014, 13:59
Re: printf Bug - by Anzipane - 06.10.2014, 14:06

Forum Jump:


Users browsing this thread: 1 Guest(s)