summaryrefslogtreecommitdiff
path: root/perl/Wallet
diff options
context:
space:
mode:
Diffstat (limited to 'perl/Wallet')
-rw-r--r--perl/Wallet/Object/Keytab.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/perl/Wallet/Object/Keytab.pm b/perl/Wallet/Object/Keytab.pm
index a818f15..f91abff 100644
--- a/perl/Wallet/Object/Keytab.pm
+++ b/perl/Wallet/Object/Keytab.pm
@@ -428,8 +428,9 @@ sub enctypes_set {
# When inserting new enctypes, we unfortunately have to do the
# consistency check against the enctypes table ourselves, since SQLite
- # doesn't enforce integrity constraints.
- for my $enctype (keys %enctypes) {
+ # doesn't enforce integrity constraints. We do this in sorted order
+ # to make it easier to test.
+ for my $enctype (sort keys %enctypes) {
$sql = 'select en_name from enctypes where en_name = ?';
my $status = $self->{dbh}->selectrow_array ($sql, undef, $enctype);
unless ($status) {