Commit 25361c52 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Symbian: kill warnings, remove unecessary includes and style on path.cpp

parent c1a3bb47
......@@ -18,14 +18,9 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include <f32file.h>
#include <e32base.h>
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
#include <wchar.h>
#include <string.h>
#include <utf.h>
#include <f32file.h> /* RFs */
#include <string.h> /* strlen */
#include <utf.h> /* CnvUtfConverter */
#include "path.h"
......@@ -62,33 +57,28 @@ extern "C" char * GetConstPrivatePath(void)
size_t len;
char carray[KMaxFileName];
if(GetPrivatePath(privatePath)!=KErrNone)
if (GetPrivatePath(privatePath) != KErrNone)
{
goto defaultreturn;
return strdup("C:\\Data\\Others");
}
CnvUtfConverter::ConvertFromUnicodeToUtf8( privatepathutf8, privatePath );
TInt index = 0;
for(index =0 ; index < privatepathutf8.Length(); index++)
for (index = 0; index < privatepathutf8.Length(); index++)
{
carray[index] = privatepathutf8[index];
}
carray[index] = 0;
if((len = strnlen((const char *)carray, KMaxFileName) < KMaxFileName)
if ((len = strnlen((const char *)carray, KMaxFileName) < KMaxFileName))
{
carray[len-1]='\0';
carray[len-1] = '\0';
return strdup((const char *)carray);
}
else
{
goto defaultreturn;
}
return strdup((const char *)carray);
defaultreturn:
return strdup("C:\\Data\\Others");
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment