/* The storage addressed by Strings is free'd prior to Split returning. */
STATIC CONST CHAR8** Split(IN CHAR8 *Strings, IN UINTN Len, OUT UINT32 *NumPtr)
/* The storage addressed by Strings is free'd prior to Split returning. */
STATIC CONST CHAR8** Split(IN CHAR8 *Strings, IN UINTN Len, OUT UINT32 *NumPtr)
{
  CONST CHAR8  **Dst;
  ASSERT (NumPtr != NULL);
  ASSERT (Strings != NULL);
  if (Len > 0) {
    Strings[Len - 1] = '\0';
  }
  *NumPtr = ExtractStrings (Strings, Len, NULL);
  Dst = AllocatePool (*NumPtr * sizeof (CHAR8 *) + Len);
  CopyMem ((VOID *)&Dst[*NumPtr], Strings, Len);
  FreePool (Strings);
  Strings = (CHAR8 *)&Dst[*NumPtr];
  ExtractStrings (Strings, Len, Dst);
  return (Dst);
}