зеркало из https://github.com/mozilla/gecko-dev.git
[Bug 505278] - nsWifiAccessPoint::GetSsid doesn't do what it thinks it does with embedded nulls. r=dbaron
This commit is contained in:
Родитель
47d3537245
Коммит
6d75c40815
|
@ -38,6 +38,7 @@
|
|||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#include "nsWifiAccessPoint.h"
|
||||
#include "nsString.h"
|
||||
#include "nsMemory.h"
|
||||
#include "prlog.h"
|
||||
|
||||
|
@ -71,11 +72,7 @@ NS_IMETHODIMP nsWifiAccessPoint::GetSsid(nsAString& aSsid)
|
|||
{
|
||||
// just assign and embedded nulls will truncate resulting
|
||||
// in a displayable string.
|
||||
|
||||
nsString tempStr;
|
||||
tempStr.AssignWithConversion(mSsid, mSsidLen);
|
||||
aSsid = tempStr;
|
||||
|
||||
CopyASCIItoUTF16(mSsid, aSsid);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче