kernel/eka/common/des16.cpp
branchGCC_SURGE
changeset 153 1f2940c968a9
parent 90 947f0dc9f7a8
equal deleted inserted replaced
151:b5dd6d3f5c21 153:1f2940c968a9
  2011 
  2011 
  2012 @see HBufC16::operator=()
  2012 @see HBufC16::operator=()
  2013 */
  2013 */
  2014 	{
  2014 	{
  2015 	__ASSERT_ALWAYS(aMaxLength>=0,Panic(ETDes16MaxLengthNegative));
  2015 	__ASSERT_ALWAYS(aMaxLength>=0,Panic(ETDes16MaxLengthNegative));
  2016 	return new(STD_CLASS::Alloc(_FOFF(HBufC16,iBuf[aMaxLength]))) HBufC16(0);
  2016 	return new(STD_CLASS::Alloc(_FOFF_DYNAMIC(HBufC16,iBuf[aMaxLength]))) HBufC16(0);
  2017 	}
  2017 	}
  2018 
  2018 
  2019 EXPORT_C HBufC16 *HBufC16::NewL(TInt aMaxLength)
  2019 EXPORT_C HBufC16 *HBufC16::NewL(TInt aMaxLength)
  2020 /**
  2020 /**
  2021 Creates, and returns a pointer to, a new 16-bit heap descriptor, and leaves 
  2021 Creates, and returns a pointer to, a new 16-bit heap descriptor, and leaves 
  2090 
  2090 
  2091 @see HBufC16::operator=()
  2091 @see HBufC16::operator=()
  2092 */
  2092 */
  2093 	{
  2093 	{
  2094 	__ASSERT_ALWAYS(aMaxLength>=0,Panic(ETDes16MaxLengthNegative));
  2094 	__ASSERT_ALWAYS(aMaxLength>=0,Panic(ETDes16MaxLengthNegative));
  2095 	return new(STD_CLASS::Alloc(_FOFF(HBufC16,iBuf[aMaxLength]))) HBufC16(aMaxLength);
  2095 	return new(STD_CLASS::Alloc(_FOFF_DYNAMIC(HBufC16,iBuf[aMaxLength]))) HBufC16(aMaxLength);
  2096 	}
  2096 	}
  2097 
  2097 
  2098 EXPORT_C HBufC16 *HBufC16::NewMaxL(TInt aMaxLength)
  2098 EXPORT_C HBufC16 *HBufC16::NewMaxL(TInt aMaxLength)
  2099 /**
  2099 /**
  2100 Creates, and returns a pointer to, a new 16-bit heap descriptor;
  2100 Creates, and returns a pointer to, a new 16-bit heap descriptor;