From 032b1422c2bdafa6938da254f1babb3fdcca60e0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Duval?= Date: Tue, 21 Jun 2022 18:32:01 +0200 Subject: [PATCH] kernel/device_manager: don't insert device node before nodes of the same priority fix #16512 Change-Id: I76ce4cfc9346492008c11ca53302ca4df6a6b514 Reviewed-on: https://review.haiku-os.org/c/haiku/+/5393 Reviewed-by: Adrien Destugues --- src/system/kernel/device_manager/device_manager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/system/kernel/device_manager/device_manager.cpp b/src/system/kernel/device_manager/device_manager.cpp index ffc539a23b..86ba40a0be 100644 --- a/src/system/kernel/device_manager/device_manager.cpp +++ b/src/system/kernel/device_manager/device_manager.cpp @@ -1454,7 +1454,7 @@ device_node::AddChild(device_node* node) device_node* before = NULL; while (iterator.HasNext()) { device_node* child = iterator.Next(); - if (child->Priority() <= priority) { + if (child->Priority() < priority) { before = child; break; }