smf/smfcredentialmgr/smfcredmgrcommon/src/smfutils.cpp
changeset 18 013a02bf2bb0
parent 14 a469c0e6e7fb
equal deleted inserted replaced
17:106a4bfcb866 18:013a02bf2bb0
     8  *
     8  *
     9  * Initial Contributors:
     9  * Initial Contributors:
    10  * Lasse Laasonen, Sasken Communication Technologies Ltd - Initial contribution
    10  * Lasse Laasonen, Sasken Communication Technologies Ltd - Initial contribution
    11  *
    11  *
    12  * Description:
    12  * Description:
    13  * This header contains utility routines used by server and client
    13  * This source contains utility routines used by server and client
       
    14  * 
    14  */
    15  */
    15 
    16 
    16 #include <s32strm.h>
    17 #include <s32strm.h>
    17 #include "smfutils.h"
    18 #include "smfutils.h"
    18 
    19 
    66 			return buf;
    67 			return buf;
    67 			}
    68 			}
    68 		else
    69 		else
    69 			return NULL;
    70 			return NULL;
    70 		}
    71 		}
       
    72 	
    71 	TInt InternalizeDesL( RBuf16& aDes, RReadStream& aStream )
    73 	TInt InternalizeDesL( RBuf16& aDes, RReadStream& aStream )
    72 	    {
    74 	    {
    73 	    TInt length = aStream.ReadInt32L();
    75 	    TInt length = aStream.ReadInt32L();
    74 	    
    76 	    
    75 	    aDes.Close();
    77 	    aDes.Close();
    83 	        aDes.CreateL( KNullDesC16 );
    85 	        aDes.CreateL( KNullDesC16 );
    84 	        }
    86 	        }
    85 
    87 
    86 	    return length;
    88 	    return length;
    87 	    }
    89 	    }
       
    90 	
    88 	void ExternalizeInt64L(const TInt64& aInt, RWriteStream& aStream)
    91 	void ExternalizeInt64L(const TInt64& aInt, RWriteStream& aStream)
    89 		{
    92 		{
    90 		TInt32 low = I64LOW( aInt );
    93 		TInt32 low = I64LOW( aInt );
    91 		TInt32 high = I64HIGH( aInt );
    94 		TInt32 high = I64HIGH( aInt );
    92 		aStream.WriteInt32L(low);
    95 		aStream.WriteInt32L(low);