Here is a problem that I am having in dialing a voice number
using the Series 60 C++ SDK. I'm using the dialer example
from the S60 SDK (DialNumber() routine attached). I'm using a
Nokia 3660. When I dial certain numbers the application crashes.
This only happens on the first attempt. Subsequent attempts do
not crash. To reproduce the problem, the phone must be
restarted. See steps below.

Can anyone help???? Has anyone seen this problem???

1. Switch on phone.

2. Dial voice number from dialer example in S60 SDK -
This number is a number where the phone network
intercepts the call. e.g. "The number you have dialed
is not in use"

3. The app crashes

- If you rerun the app and dial the same number without
restarting the phone, everything is ok - i.e. the app does not
crash and the phone displays a "Number not in use" message.

- RCall::Dial(number) crashes - it does not leave or return
an error status. Note this is a synchronous call.

- The asynchronous version of RCall::Dial crashes also if used.

- Doing everthing once except RCall::Dial on app startup and then
doing everthing again including RCall::Dial), does not fix the
problem. So it looks like ETel/RCall::Dial is 'righting' itself before
the first crash.

- If the call is completed and the receiving side answers then the
problem does not occur.


void CDialerAppUi::DialNumberL(const TDesC& aPhoneNumber)
// emulator does not support dialing
#if __WINS__
NEikonEnvironment::MessageBox (KEmulatorError);

//Create a connection to the tel server
RTelServer server;

//Load in the phone device driver

//Find the number of phones available from the tel server
TInt numberPhones;

//Check there are available phones
if (numberPhones < 1)

//Get info about the first available phone
RTelServer::TPhoneInfo info;
User::LeaveIfError(server.GetPhoneInfo(0, info));

//Use this info to open a connection to the phone, the phone is identified by its name
RPhone phone;
User::LeaveIfError(phone.Open(server, info.iName));

//Get info about the first line from the phone
RPhone::TLineInfo lineInfo;
User::LeaveIfError(phone.GetLineInfo(0, lineInfo));

//Use this to open a line
RLine line;
User::LeaveIfError(line.Open(phone, lineInfo.iName));

//Open a new call on this line
TBuf <100> newCallName;
RCall call;
User::LeaveIfError(call.OpenNewCall(line, newCallName));

//newCallName will now contain the name of the call

//Close the phone, line and call connections and remove them from the cleanup stack
//NOTE: This does not hang up the call
CleanupStack::PopAndDestroy(3);//phone, line, call

//Unload the phone device driver

//Close the connection to the tel server and remove it from the cleanup stack