Adhemerval Zanella 9752c3cdbc libio: Fix buffer overrun in tst-ftell-active-handler
On 'do_ftell_test' the code:

365           if (test_modes[i].fd_mode != O_WRONLY)
366             {
367               char tmpbuf[data_len];
368
369               rewind (fp);
370
371               while (fgets_func (tmpbuf, sizeof (tmpbuf), fp) && !feof (fp));

The 'data_len' is calculated with wsclen and allocated as 'char'.  The
subsequent fgetws will then try to write at most 'data_len' wchar_t
in a buffer with just data_len 'char'.  This patch fixes it by
allocating the tmpbuf using 'wchar_t' * data_len bytes.
2014-12-05 07:41:22 -05:00
..
2006-08-14 22:16:14 +00:00
2009-09-02 19:45:33 -07:00
2014-11-12 16:22:51 +00:00
2014-12-04 08:45:55 +05:30
2014-11-12 16:22:51 +00:00
2014-12-04 08:45:55 +05:30
2014-11-12 16:22:51 +00:00
2012-05-24 23:06:20 +02:00
2014-11-24 15:03:45 +05:30
2006-01-19 01:35:28 +00:00
2006-12-13 23:17:54 +00:00
2014-12-04 08:45:55 +05:30