×

Discussion Board

Results 1 to 8 of 8
  1. #1
    Registered User
    Join Date
    Sep 2009
    Posts
    9

    HBufC::NewL(1) leaves why?

    I have developed a Client/Server application that runs fine on the emulator.

    On the device however I get a System Error on startup.

    Debugging on the device shows it occurs inside the ConstructL of the CActive based class when it tries

    HBufC::NewL(4096) - I've tried a value of 1 (to rule out memory availability) as well and get the same error.

    When I trap it the error code is 6292496?

    I don't know what to make of this given the emulator runs it fine

    Thanks

  2. #2
    Registered User
    Join Date
    Jan 2007
    Posts
    282

    Re: HBufC::NewL(1) leaves why?

    Error code of 6292496 seems to make no sense as all symbian leave codes are negative integers. Also HBufC::NewL(1) will leave only in very rare scenarios when your application has consumed all its available memory. With default heap of 1 MB typical application dont often use it entirely. Please recheck your code if your code is building properly or not.

    Regarding HBufC::NewL(4096) , its quite possible that you are running out of heap here. HBUfC always need a 4K size of continuous memory chunk so its quite possible to run out of memory here. The simplest solution would be to increase your heap size using EPOCHEAPSIZE statement in your mmp:

    EPOCHEAPSIZE 4096 2000000
    will allocate minimum heap of 4K and maximum of abt 2 MB.

    A much better approach then increasing heap size would be to CBufSeg instances for your task.

    Hope that helps,
    VJ

  3. #3
    Nokia Developer Champion
    Join Date
    Jul 2004
    Posts
    2,015

    Re: HBufC::NewL(1) leaves why?

    >>6292496

    I don't have my calculator, is that -4 wrapping around into a positive value




    "HBUfC always need a 4K size of continuous memory chunk"

    So you are saying if I want to allocate a HBufC 1 byte long, I will actually require 4096 bytes? Maybe you are confusing the fact that HBufC's allocated amount gets rounded up to a 4 byte multiple?
    Last edited by hotcheese; 2009-12-07 at 16:33.

  4. #4
    Registered User
    Join Date
    Jan 2007
    Posts
    282

    Re: HBufC::NewL(1) leaves why?

    Hi hotcheese,

    6292496 isnt a 2's complement of -4 when you consider TUint size of 4 bytes. Thats why the value seems to have no sense to me, as only leave that i have practically seen with HBufC::NewL are KErrNoMemory (-4).

    Regarding: "HBUfC always need a 4K size of continuous memory chunk" HBufC will allocate continuous memory chunk of that size. I never meant that HBufC::NewL(1) will allocate 4K bytes of memory.

    4 byte memory alignment is a constraint of ARM architecture. Its not the constraint of the symbian library. However Armv6 allows unaligned access to memory and who know when symbian base libraries may start exploiting that.

    Hope that helps,
    VJ

  5. #5
    Registered User
    Join Date
    Sep 2009
    Posts
    9

    Re: HBufC::NewL(1) leaves why?

    Thanks for help so far, although the suggested mmp file entry for increasing the heap didnt work. Maybe it is build not working then, here's the build log, it only has warnings so I've assumed it has built all ok, but maybe I'm wrong

    I have to chop off the first 1000 chars because the post limits to 10000 chars

    ***Invoking abld command
    perl.exe -S ABLD.PL \myAsync\group\ resource gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\GCCE.make" RESOURCE CFG=UREL VERBOSE=-s
    Created \Symbian\9.1\S60_3rd_MR\EPOC32\INCLUDE\myAsync.RSG
    make -s -C \myAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\.. EPOCBLD=..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\myAsync\group PLATFORM=GCCE CFG=UREL RESOURCE
    Checking: ..\gfx\qgn_menu_myasync.svg
    Choosing...
    Loading mif icons...
    Loading file: ..\gfx\qgn_menu_myasync.svg
    Writing mif: \Symbian\9.1\S60_3rd_MR\epoc32\data\z\resource\apps\myasync.mif
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNCSERVER\GCCE\MYASYNCSERVER.GCCE" RESOURCEUREL
    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNCSERVER\GCCE\UREL
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNC\GCCE\MYASYNC.GCCE" RESOURCEUREL


    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNC\GCCE\UREL

    Total Time: 9 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \myAsync\group\ target gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\GCCE.make" TARGET CFG=UREL VERBOSE=-s
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    ..\\SERVER\\crafty\\Analyze.c: In function `Analyze_ITER':
    ..\\SERVER\\crafty\\Analyze.c:271: warning: implicit declaration of function `ITER_Iterate_INIT'
    ..\\SERVER\\crafty\\Analyze.c:276: warning: implicit declaration of function `ITER_Iterate_LOOP_1'
    ..\\SERVER\\crafty\\Analyze.c:284: warning: implicit declaration of function `ITER_Iterate_LOOP_2'
    ..\\SERVER\\crafty\\Analyze.c:287: warning: implicit declaration of function `ITER_Iterate_LOOP_5'
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    ..\\SERVER\\crafty\\Boolean.c: In function `FirstOne':
    ..\\SERVER\\crafty\\Boolean.c:82: warning: suggest parentheses around assignment used as truth value
    ..\\SERVER\\crafty\\Boolean.c:84: warning: suggest parentheses around assignment used as truth value
    ..\\SERVER\\crafty\\Boolean.c: In function `LastOne':
    ..\\SERVER\\crafty\\Boolean.c:92: warning: suggest parentheses around assignment used as truth value
    ..\\SERVER\\crafty\\Boolean.c:94: warning: suggest parentheses around assignment used as truth value
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    ..\\SERVER\\crafty\\Iterate.c: In function `ITER_Iterate_LOOP':
    ..\\SERVER\\crafty\\Iterate.c:1258: warning: control reaches end of non-void function
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    ..\\SERVER\\crafty\\Option.c:2238:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2305:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2343:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2384:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2409:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2831:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2902:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:2918:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:3084:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:3105:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:3843:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:3855:1: warning: "/*" within comment
    ..\\SERVER\\crafty\\Option.c:3937:1: warning: "/*" within comment
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    cc1.exe: warning: command line option "-Wno-ctor-dtor-privacy" is valid for C++/ObjC++ but not for C
    ..\\SERVER\\crafty\\Utility.c: In function `MyInterupt':
    ..\\SERVER\\crafty\\Utility.c:3045: warning: implicit declaration of function `ITER_Iterate_LOOP_4'
    ..\\SERVER\\crafty\\Utility.c:3046: warning: implicit declaration of function `ITER_Iterate_LOOP_5'
    In file included from ..\\CLIENT\\src\\Myasyncappui.cpp:18:
    ..//..//Symbian//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h: In member function `TBool CEikMenuPaneItem::IsScaleableText(const TDesC&) const':
    ..//..//Symbian//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h:183: warning: enumeral mismatch in conditional expression: `TFalse' vs `TTrue'
    make -j 4 -s -C \myAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\.. EPOCBLD=..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\myAsync\group PLATFORM=GCCE CFG=UREL BLD
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNCSERVER\GCCE\MYASYNCSERVER.GCCE" UREL
    Mysession.cpp
    Myserver.cpp
    Analyze.c
    Attacks.c
    Book.c
    Boolean.c
    Data.c
    Evaluate.c
    Hash.c
    Init.c
    Input.c
    Interupt.c
    Iterate.c
    Killer.c
    Main.c
    Make.c
    Movgen.c
    Next.c
    Option.c
    Output.c
    Preeval.c
    Quiesce.c
    Repeat.c
    Resign.c
    Root.c
    Search.c
    Setboard.c
    Swap.c
    Unmake.c
    Utility.c
    Drawn.c
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\MYASYNC\GCCE\MYASYNC.GCCE" UREL
    Myasyncrequesthandler.cpp
    Myasyncserversession.cpp
    Myasync.cpp
    Myasyncapplication.cpp
    Myasyncappview.cpp
    Myasyncappui.cpp
    Myasyncdocument.cpp

    Total Time: 1 min, 49 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \myAsync\group\ final gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\GCCE.make" FINAL CFG=UREL VERBOSE=-s
    make -j 4 -s -C \myAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\.. EPOCBLD=..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\myAsync\group PLATFORM=GCCE CFG=UREL FINAL

    Total Time: 1 min, 51 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \myAsync\group\ test export
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\myAsync\group\EXPORTtest.make" EXPORT VERBOSE=-s
    Nothing to do

    Total Time: 1 min, 51 sec

    ***Build Complete

    Total Time: 1 min, 51 sec

  6. #6
    Registered User
    Join Date
    Sep 2009
    Posts
    9

    Re: HBufC::NewL(1) leaves why?

    I have just noticed and this may be the problem that when ODD the CActive object shows as Invalid Format, does this mean that my derived class was not instantiated properly and hence why its ConstructL method has trouble calling HBufC::NewL?

    Thanks

  7. #7
    Registered User
    Join Date
    Sep 2009
    Posts
    9

    Re: HBufC::NewL(1) leaves why?

    Update:

    I have ruled out the "Invalid Format" value for the CActive object and that it mght be the build by doing the following.

    I took the ClientServerAsync example application from the SDK and added a member to the casyncrequesthandler.h as follows (line in bold)

    Code:
            */
            TTime iTime;
    
            /**
            * iObserver, observer which handles updates from the server.
            */
            MAsyncTimeObserver& iObserver;
            
            // Test 
            HBufC *iMyBuffer;
    I added a line in the ConstructL method of casyncrequesthandler.cpp as follows (also in bold)

    Code:
    // -----------------------------------------------------------------------------
    // CCSAsyncRequestHandler::ConstructL()
    // Symbian 2nd phase constructor can leave.
    // -----------------------------------------------------------------------------
    //
    void CCSAsyncRequestHandler::ConstructL()
        {
        TRAPD(errorcode,iMyBuffer = HBufC::NewL(4096));
        User::LeaveIfError( iSession.Connect() );
        }
    This also produces the error described earlier in the thread namely the HBufC::NewL leaves with a code of 6304896

    Here is the build log for the example as above


    ***Building project "ClientServerAsync" for configuration "Phone Debug (GCCE) [S60_3rd_MR]"

    ***Printing environment variables modified from default:
    PATH=C:\Symbian\9.1\S60_3rd_MR\epoc32\tools;C:\Symbian\9.1\S60_3rd_MR\epoc32\gcc\bin;C:/Program Files/Nokia/Carbide.c++ v2.0/jre/bin/client;C:/Program Files/Nokia/Carbide.c++ v2.0/jre/bin;C:\Program Files\Common Files\Symbian\Tools;C:\Program Files\Nokia\Carbide.c++ v2.0\x86Build\Symbian_Tools\Command_Line_Tools;C:\Program Files\CSL Arm Toolchain\bin;C:\Perl\bin\;C:\Program Files\PC Connectivity Solution\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Common Files\Roxio Shared\DLLShared;C:\Program Files\QuickTime\QTSystem\
    EPOCROOT=\Symbian\9.1\S60_3rd_MR\
    NO_DEPENDENCIES=-nd
    MAKE=make -j 4

    Working Directory: C:/Symbian/Carbide/workspaceMR/ClientServerAsync/group

    ***Makefile structures up to date. Skipping 'bldmake bldfiles'

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ export
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\EXPORT.make" EXPORT VERBOSE=-s
    Nothing to do

    Total Time: 0 sec

    ***Generating abld makefile.

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ makefile gcce icons_aif_scalable
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\GCCE.make" MAKEFILEICONS_AIF_SCALABLE VERBOSE=-s
    make -j 4 -s -C \Symbian\Carbide\workspaceMR\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\Symbian\Carbide\workspaceMR\ClientServerAsync\group PLATFORM=GCCE MAKMAKE

    Total Time: 0 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ library gcce
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\GCCE.make" LIBRARY VERBOSE=-s
    make -s -C \Symbian\Carbide\workspaceMR\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\Symbian\Carbide\workspaceMR\ClientServerAsync\group PLATFORM=GCCE LIB
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" LIBRARY
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" LIBRARY

    Total Time: 4 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ resource gcce udeb
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\GCCE.make" RESOURCE CFG=UDEB VERBOSE=-s
    Created \Symbian\9.1\S60_3rd_MR\EPOC32\INCLUDE\CSAsync.RSG
    make -s -C \Symbian\Carbide\workspaceMR\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\Symbian\Carbide\workspaceMR\ClientServerAsync\group PLATFORM=GCCE CFG=UDEB RESOURCE
    Checking: ..\gfx\qgn_menu_csasync.svg
    Choosing...
    Loading mif icons...
    Loading file: ..\gfx\qgn_menu_csasync.svg
    Writing mif: \Symbian\9.1\S60_3rd_MR\epoc32\data\z\resource\apps\csasync.mif
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" RESOURCEUDEB
    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNCSERVER\GCCE\UDEB
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" RESOURCEUDEB


    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNC\GCCE\UDEB

    Total Time: 9 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ target gcce udeb
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\GCCE.make" TARGET CFG=UDEB VERBOSE=-s
    In file included from ..//SERVER//inc/TimeServer.h:22,
    from ..\\SERVER\\src\\Timeserver.cpp:21:
    ..//SERVER//inc/AsyncServer.pan:37:15: warning: no newline at end of file
    In file included from ..\\SERVER\\src\\Timeserver.cpp:22:
    ..//client//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\SERVER\\src\\Timesession.cpp:21:
    ..//client//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..//SERVER//inc/TimeServer.h:22,
    from ..\\SERVER\\src\\Timesession.cpp:22:
    ..//SERVER//inc/AsyncServer.pan:37:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Timeserversession.cpp:20:
    ..//CLIENT//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncrequesthandler.cpp:21:
    ..//CLIENT//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncrequesthandler.cpp:22:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncappui.cpp:18:
    ..//..//..//..//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h: In member function `TBool CEikMenuPaneItem::IsScaleableText(const TDesC&) const':
    ..//..//..//..//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h:183: warning: enumeral mismatch in conditional expression: `TFalse' vs `TTrue'
    In file included from ..//CLIENT//inc/CSAsyncAppUi.h:22,
    from ..\\CLIENT\\src\\Csasyncdocument.cpp:17:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    In file included from ..//CLIENT//inc/CSAsyncAppUi.h:22,
    from ..\\CLIENT\\src\\Csasyncappui.cpp:23:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncappui.cpp:26:
    ..//CLIENT//inc/CSAsync.hrh:31:15: warning: no newline at end of file
    make -j 4 -s -C \Symbian\Carbide\workspaceMR\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\Symbian\Carbide\workspaceMR\ClientServerAsync\group PLATFORM=GCCE CFG=UDEB BLD
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" UDEB
    Timesession.cpp
    Timeserver.cpp
    1 file(s) copied.
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" UDEB
    Csasyncrequesthandler.cpp
    Timeserversession.cpp
    Csasync.cpp
    Csasyncapplication.cpp
    Csasyncappview.cpp
    Csasyncappui.cpp
    Csasyncdocument.cpp
    1 file(s) copied.

    Total Time: 45 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ final gcce udeb
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\GCCE.make" FINAL CFG=UDEB VERBOSE=-s
    make -j 4 -s -C \Symbian\Carbide\workspaceMR\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\Symbian\Carbide\workspaceMR\ClientServerAsync\group PLATFORM=GCCE CFG=UDEB FINAL

    Total Time: 46 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \Symbian\Carbide\workspaceMR\ClientServerAsync\group\ test export
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\Symbian\Carbide\workspaceMR\ClientServerAsync\group\EXPORTtest.make" EXPORT VERBOSE=-s
    Nothing to do

    Total Time: 49 sec

    ***Build Complete

    Total Time: 49 sec

  8. #8
    Nokia Developer Champion
    Join Date
    Mar 2004
    Posts
    130

    Re: HBufC::NewL(1) leaves why?

    I tried to edit ClientServerAsync example like you told but everything works fine for me. Compiler also show the same output like you copied.

    ***Building project "ClientServerAsync" for configuration "Phone Release (GCCE) [S60_3rd_MR]"

    ***Printing environment variables modified from default:
    PATH=C:\Symbian\9.1\S60_3rd_MR\epoc32\tools;C:\Symbian\9.1\S60_3rd_MR\epoc32\gcc\bin;C:/Program Files/Nokia/Carbide.c++ v2.0/jre/bin/client;C:/Program Files/Nokia/Carbide.c++ v2.0/jre/bin;C:\Program Files\PC Connectivity Solution\;C:\PROGRA~1\Common Files\Symbian\Tools;C:\PROGRA~1\PC Connectivity Solution\;C:\PROGRA~1\ARM\bin\win_32-pentium;C:\PROGRA~1\CSL Arm Toolchain\bin;C:\Perl\bin\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\PROGRA~1\Java\jre6\bin;C:\PROGRA~1\ARM\RVCT\Programs\2.2\349\win_32-pentium;C:\PROGRA~1\ARM\Utilities\FLEXlm\9.2\release\win_32-pentium;D:\Neois\Installer\Android SDK\android-sdk-windows-1.0_r1\tools;C:\PROGRA~1\Flash Magic;C:\PROGRA~1\QuickTime\QTSystem\;C:\Program Files\Java\jdk1.6.0\bin;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Common Files\Acronis\SnapAPI\;C:\Program Files\Nokia\Carbide.c++ v2.0\x86Build\Symbian_Tools\Command_Line_Tools;C:\Program Files\HookLogger\;C:\Program Files\AppServ\Apache2.2\bin;C:\Program Files\AppServ\MySQL\bin;C:\Program Files\AppServ\Apache2.2\bin;C:\Program Files\AppServ\php5;C:\Program Files\AppServ\MySQL\bin;C:\Program Files\Acronis\BackupAndRecovery\;;C:\PROGRA~1\FLASHM~1
    EPOCROOT=\Symbian\9.1\S60_3rd_MR\
    NO_DEPENDENCIES=-nd
    MAKE=make -j 4

    Working Directory: C:/SymbianProjects/workspaces/Lab/ClientServerAsync/group

    ***Makefile structures up to date. Skipping 'bldmake bldfiles'

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ export
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\EXPORT.make" EXPORT VERBOSE=-s
    Nothing to do

    Total Time: 0 sec

    ***Generating abld makefile.

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ makefile gcce icons_aif_scalable
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\GCCE.make" MAKEFILEICONS_AIF_SCALABLE VERBOSE=-s
    make -j 4 -s -C \SymbianProjects\workspaces\Lab\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\SymbianProjects\workspaces\Lab\ClientServerAsync\group PLATFORM=GCCE MAKMAKE

    Total Time: 0 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ library gcce
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\GCCE.make" LIBRARY VERBOSE=-s
    make -s -C \SymbianProjects\workspaces\Lab\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\SymbianProjects\workspaces\Lab\ClientServerAsync\group PLATFORM=GCCE LIB
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" LIBRARY
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" LIBRARY

    Total Time: 0 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ resource gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\GCCE.make" RESOURCE CFG=UREL VERBOSE=-s
    Created \Symbian\9.1\S60_3rd_MR\EPOC32\INCLUDE\CSAsync.RSG
    make -s -C \SymbianProjects\workspaces\Lab\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\SymbianProjects\workspaces\Lab\ClientServerAsync\group PLATFORM=GCCE CFG=UREL RESOURCE
    Checking: ..\gfx\qgn_menu_csasync.svg
    Choosing...
    Loading mif icons...
    Loading file: ..\gfx\qgn_menu_csasync.svg
    Writing mif: \Symbian\9.1\S60_3rd_MR\epoc32\data\z\resource\apps\csasync.mif
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" RESOURCEUREL
    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNCSERVER\GCCE\UREL
    make -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" RESOURCEUREL


    Creating \Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNC\GCCE\UREL

    Total Time: 1 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ target gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\GCCE.make" TARGET CFG=UREL VERBOSE=-s
    In file included from ..\\SERVER\\src\\Timesession.cpp:21:
    ..//client//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..//SERVER//inc/TimeServer.h:22,
    from ..\\SERVER\\src\\Timesession.cpp:22:
    ..//SERVER//inc/AsyncServer.pan:37:15: warning: no newline at end of file
    In file included from ..//SERVER//inc/TimeServer.h:22,
    from ..\\SERVER\\src\\Timeserver.cpp:21:
    ..//SERVER//inc/AsyncServer.pan:37:15: warning: no newline at end of file
    In file included from ..\\SERVER\\src\\Timeserver.cpp:22:
    ..//client//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncrequesthandler.cpp:21:
    ..//CLIENT//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncrequesthandler.cpp:22:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Timeserversession.cpp:20:
    ..//CLIENT//inc/ClientServerCommon.h:50:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncappui.cpp:18:
    ..//..//..//..//..//Symbian//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h: In member function `TBool CEikMenuPaneItem::IsScaleableText(const TDesC&) const':
    ..//..//..//..//..//Symbian//9.1//S60_3rd_MR//EPOC32//include/eikmenup.h:183: warning: enumeral mismatch in conditional expression: `TFalse' vs `TTrue'
    In file included from ..//CLIENT//inc/CSAsyncAppUi.h:22,
    from ..\\CLIENT\\src\\Csasyncappui.cpp:23:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    In file included from ..\\CLIENT\\src\\Csasyncappui.cpp:26:
    ..//CLIENT//inc/CSAsync.hrh:31:15: warning: no newline at end of file
    In file included from ..//CLIENT//inc/CSAsyncAppUi.h:22,
    from ..\\CLIENT\\src\\Csasyncdocument.cpp:17:
    ..//CLIENT//inc/AsyncTimeObserver.h:38:15: warning: no newline at end of file
    make -j 4 -s -C \SymbianProjects\workspaces\Lab\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\SymbianProjects\workspaces\Lab\ClientServerAsync\group PLATFORM=GCCE CFG=UREL BLD
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNCSERVER\GCCE\CSASYNCSERVER.GCCE" UREL
    Timesession.cpp
    Timeserver.cpp
    make -j 4 -s -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\CSASYNC\GCCE\CSASYNC.GCCE" UREL
    Csasyncrequesthandler.cpp
    Timeserversession.cpp
    Csasync.cpp
    Csasyncapplication.cpp
    Csasyncappview.cpp
    Csasyncappui.cpp
    Csasyncdocument.cpp

    Total Time: 5 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ final gcce urel
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\GCCE.make" FINAL CFG=UREL VERBOSE=-s
    make -j 4 -s -C \SymbianProjects\workspaces\Lab\ClientServerAsync\CLIENT\GROUP -f "ICONS_AIF_SCALABLE.MK" TO_ROOT=..\..\..\..\..\.. EPOCBLD=..\..\..\..\..\..\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\ICONS_AIF_SCALABLE\GCCE TO_BLDINF=..\..\..\..\..\..\SymbianProjects\workspaces\Lab\ClientServerAsync\group PLATFORM=GCCE CFG=UREL FINAL

    Total Time: 5 sec

    ***Invoking abld command
    perl.exe -S ABLD.PL \SymbianProjects\workspaces\Lab\ClientServerAsync\group\ test export
    make -r -f "\Symbian\9.1\S60_3rd_MR\EPOC32\BUILD\SymbianProjects\workspaces\Lab\ClientServerAsync\group\EXPORTtest.make" EXPORT VERBOSE=-s
    Nothing to do

    Total Time: 5 sec

    ***Build Complete

    ***Invoking makesis.exe ....
    ...

    ***Invoking makekeys....
    ...

    ***Invoking signsis.exe....
    ...

    ***SIS Creation Complete

    Total Time: 16 sec
    Please check the source code and test it on your device (sisx included). http://www.nuuneoi.com/files/ClientServerAsync.zip

Similar Threads

  1. C++ exceptions VS Symbian Leaves :)
    By metalim in forum Symbian
    Replies: 18
    Last Post: 2009-04-15, 11:54
  2. HookLogger and leaves monitoring
    By nuker85 in forum Symbian Tools & SDKs
    Replies: 5
    Last Post: 2008-11-27, 07:51
  3. Commiting change on CMsvEntry using ChangeL leaves
    By dejan_medic in forum Symbian Networking & Messaging (Closed)
    Replies: 1
    Last Post: 2008-08-10, 08:37
  4. Why leaves with KErrOverflow???
    By supersuperguo in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2007-10-16, 08:49
  5. About leaves on HTTP API.
    By kosjanne in forum Symbian Networking & Messaging (Closed)
    Replies: 0
    Last Post: 2005-04-15, 07:41

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •