Exemplo n.º 1
0
NS_CStringGetData(const nsACString& aStr, const char** aData,
                  bool* aTerminated)
{
  if (aTerminated) {
    *aTerminated = aStr.IsTerminated();
  }

  *aData = aStr.BeginReading();
  return aStr.Length();
}
Exemplo n.º 2
0
NS_CStringGetData(const nsACString &aStr, const char **aData,
                  bool *aTerminated)
{
  if (aTerminated)
    *aTerminated = aStr.IsTerminated();

  nsACString::const_iterator begin;
  aStr.BeginReading(begin);
  *aData = begin.get();
  return begin.size_forward();
}