Subject Are Deadlocks realy handled correct?

I just build up a simple Situation in which to Java-Programs
wants to update the same two records. The Program is quite

Class.forName( "org.firebirdsql.jdbc.FBDriver" );
conn =
"sysdba", "masterkey");
conn.setAutoCommit( false );
stat = conn.createStatement();
// first program
int i = stat.executeUpdate( "UPDATE TEST SET IDENT = 777 WHERE IDENT =
123" );
// second program
//int i = stat.executeUpdate( "UPDATE TEST SET IDENT = 555 WHERE IDENT =
123" );
System.out.println("excuted " + i + " updates" );
// First Program
i = stat.executeUpdate( "UPDATE TEST SET IDENT = 888 WHERE IDENT = 456"
// Second program
//i = stat.executeUpdate( "UPDATE TEST SET IDENT = 666 WHERE IDENT =
456" );
System.out.println("excuted " + i + " updates" );

As you can see they try to update the records cross-over. Stepping in
debug mode
both programms to the first System.out, everything works fine. Stepping
with the
first program over the second update the program blocks. So far so fine.
I take the second progam trying to step over the second update. In this
I get an "GDSexception: deadlock" now. But the other program keeps on
and no other program can update these records. They all block too.

Does not have the first program been send an exception too or perhaps
making him able
to end its transaction?

Are there any known problems with deadlocks?

Is there anything wrong with my environment? I use Firebird 1.0 and
JBuilder 4.0.
Both run on Windows. Isolation on server ist set to concurrency.

Hans Georg