mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 22:01:30 +00:00
[Bug 505278] - nsWifiAccessPoint::GetSsid doesn't do what it thinks it does with embedded nulls. r=dbaron
This commit is contained in:
parent
47d3537245
commit
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;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user