[USETUP]: Formatting fix & remove a redundant function.

svn path=/trunk/; revision=70468
This commit is contained in:
Hermès Bélusca-Maïto 2015-12-30 18:52:07 +00:00
parent c7272cefad
commit ef915b1472

View file

@ -42,9 +42,7 @@ IniCacheFreeKey(
PINICACHEKEY Next;
if (Key == NULL)
{
return NULL;
}
Next = Key->Next;
if (Key->Name != NULL)
@ -73,9 +71,7 @@ IniCacheFreeSection(
PINICACHESECTION Next;
if (Section == NULL)
{
return NULL;
}
Next = Section->Next;
while (Section->FirstKey != NULL)
@ -209,42 +205,6 @@ IniCacheAddKey(
}
#if 0
static
PINICACHESECTION
IniCacheFindSection(
PINICACHE Cache,
PWCHAR Name,
ULONG NameLength)
{
PINICACHESECTION Section = NULL;
if (Cache == NULL || Name == NULL || NameLength == 0)
{
return NULL;
}
Section = Cache->FirstSection;
/* iterate through list of sections */
while (Section != NULL)
{
if (NameLength == wcslen(Section->Name))
{
/* are the contents the same too? */
if (_wcsnicmp(Section->Name, Name, NameLength) == 0)
break;
}
/* get the next section*/
Section = Section->Next;
}
return Section;
}
#endif
static
PINICACHESECTION
IniCacheAddSection(
@ -351,7 +311,7 @@ IniCacheGetSectionName(
*NamePtr = NULL;
*NameSize = 0;
/* skip whitespace */
/* Skip whitespace */
while (*Ptr != 0 && isspace(*Ptr))
{
Ptr++;
@ -401,7 +361,7 @@ IniCacheGetKeyName(
*NameSize = 0;
Size = 0;
/* skip whitespace and empty lines */
/* Skip whitespace and empty lines */
while (isspace(*Ptr) || *Ptr == '\n' || *Ptr == '\r')
{
Ptr++;
@ -703,9 +663,7 @@ IniCacheDestroy(
PINICACHE Cache)
{
if (Cache == NULL)
{
return;
}
while (Cache->FirstSection != NULL)
{