[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-bugs-dist
Subject: [Bug 90004] Filedialog crash when saving in directory with long
From: Aaron Williams <aaron_williams () net ! com>
Date: 2005-01-05 23:02:55
Message-ID: 20050105230255.14347.qmail () ktown ! kde ! org
[Download RAW message or body]
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.
http://bugs.kde.org/show_bug.cgi?id=90004
------- Additional Comments From aaron_williams net com 2005-01-06 00:02 -------
I wrote one simple patch that works for Solaris after I tracked down the
source of the bug.. I had to apply it to 3.3.2 as well.
Basically I added the code to allocate the appropriate space for
dirPosition and later free it.
i.e.
// Get maximum file name size for this directory
int max_name_length = pathconf( QFile::encodeName( *it ),
_PC_NAME_MAX);
// Allocate position storage
dirPosition = (struct dirent *)malloc(sizeof(dirent) +
max_name_length + 1);
while ( !terminationRequested() &&
::readdir_r( dir, dirPosition, &dirEntry ) == 0 &&
dirEntry )
{
...
}
free(dirPosition);
dirPosition=0;
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic