tinycc-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] Fix for Microsoft compilers


From: Sergey Korshunoff
Subject: Re: [Tinycc-devel] Fix for Microsoft compilers
Date: Sun, 12 Apr 2015 19:53:34 +0300

Hi!

> Oh my, get_tok_str returns a pointer to a local variable. So the proper fix
> would be to make get_tok_str take a CString as parameter and have the caller
> allocate the buffer associated with the CString. And then it's just a matter 
> of
> allocating buf to STRING_MAX_SIZE.

But there is a buf1 too. A buf declaration is already moved to a buf1
declaration in the mob.
Changing get_tok_str -- there is a big anount of usage points. A bound
checking code is working with the current implementation of the
get_tok_str. It is checked recently.

PS: who know why __bound_init from the ".init" section don't called on
windows? A test case: remove calls to __bound_init() from the bcheck.c
and bound checking stops working.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]