equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2007 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of "Eclipse Public License v1.0" |
5 * under the terms of "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
278 |
278 |
279 FTRACE(FPrint( |
279 FTRACE(FPrint( |
280 _L("[USBREMOTEPERSONALITY]\tCRemotePersonalityHandler::GetPersonalities Response length is %d bytes" ), responseLength)); |
280 _L("[USBREMOTEPERSONALITY]\tCRemotePersonalityHandler::GetPersonalities Response length is %d bytes" ), responseLength)); |
281 |
281 |
282 aPersonalities.Close(); |
282 aPersonalities.Close(); |
283 aPersonalities.Create(responseLength); |
283 aPersonalities.CreateL(responseLength); |
284 |
284 |
285 // Panic on Append never can be rised in this method, due to aPersonalities length exactly equal the appending data length. |
285 // Panic on Append never can be rised in this method, due to aPersonalities length exactly equal the appending data length. |
286 aPersonalities.Append(responseLength); |
286 aPersonalities.Append(responseLength); |
287 aPersonalities.Append(KAllPersonalitiesDescriptorType); // All Personalities Descriptor type |
287 aPersonalities.Append(KAllPersonalitiesDescriptorType); // All Personalities Descriptor type |
288 |
288 |
460 User::Leave(EInvalidRequest); |
460 User::Leave(EInvalidRequest); |
461 |
461 |
462 } |
462 } |
463 |
463 |
464 aLastResult.Close(); |
464 aLastResult.Close(); |
465 aLastResult.Create(1); // Length of response to GetLastResult request is 1 byte always. |
465 aLastResult.CreateL(1); // Length of response to GetLastResult request is 1 byte always. |
466 |
466 |
467 // Panic on Append never can be rised here, due to aPersonalities length exactly equal the appending data length. |
467 // Panic on Append never can be rised here, due to aPersonalities length exactly equal the appending data length. |
468 aLastResult.Append(static_cast<TInt8>(iLastResult)); |
468 aLastResult.Append(static_cast<TInt8>(iLastResult)); |
469 |
469 |
470 } |
470 } |