diff -urp old/acl.install new/acl.install
--- old/acl.install	2008-03-13 03:18:00.000000000 +0530
+++ new/acl.install	2008-03-18 18:17:10.156250000 +0530
@@ -8,7 +8,8 @@ function acl_install() {
       db_query("create table if not exists {acl} (
         acl_id int(10) NOT NULL default 0,
         module varchar(255),
-        name varchar(255),
+        name varchar(255),
+        priority tinyint(4) NOT NULL default '0', 
         PRIMARY KEY (acl_id)
         ) /*!40100 DEFAULT CHARACTER SET utf8 */;");
 
@@ -24,7 +25,7 @@ function acl_install() {
         nid int(10) NOT NULL default 0,
         grant_view tinyint(1) unsigned NOT NULL default '0',
         grant_update tinyint(1) unsigned NOT NULL default '0',
-        grant_delete tinyint(1) unsigned NOT NULL default '0',
+        grant_delete tinyint(1) unsigned NOT NULL default '0',
         PRIMARY KEY (acl_id, nid)
         ) /*!40100 DEFAULT CHARACTER SET utf8 */;");
       break;
@@ -33,7 +34,8 @@ function acl_install() {
       db_query("CREATE TABLE {acl} (
         acl_id integer NOT NULL DEFAULT 0,
         module varchar(255),
-        name varchar(255),
+        name varchar(255),
+        priority smallint NOT NULL default 0,
         PRIMARY KEY (acl_id)
       );");
       db_query("CREATE SEQUENCE {acl}_acl_id_seq;");
@@ -50,7 +52,7 @@ function acl_install() {
         nid int NOT NULL DEFAULT 0,
         grant_view smallint NOT NULL default 0,
         grant_update smallint NOT NULL default 0,
-        grant_delete smallint NOT NULL default 0,
+        grant_delete smallint NOT NULL default 0,
         PRIMARY KEY (acl_id, nid)
       );");
       break;
@@ -169,3 +171,21 @@ function acl_update_5() {
   db_query("DELETE FROM {acl_user} WHERE uid NOT IN (SELECT uid FROM {users})");
   return $ret;
 }
+
+/**
+ * Add 'prioirty' to ACL_node.
+ */
+function acl_update_6() {
+  $ret = array();
+  switch ($GLOBALS['db_type']) {
+    case 'mysql':
+    case 'mysqli':
+      db_add_column($ret, 'acl', 'priority', 'tinyint(4)', array('default' => '0'));
+      break;
+    case 'pgsql':
+      db_add_column($ret, 'acl', 'priority', 'smallint', array('default' => '0'));
+      break;
+  }
+  return $ret;
+
+}
\ No newline at end of file
diff -urp old/acl.module new/acl.module
--- old/acl.module	2008-03-13 03:18:00.000000000 +0530
+++ new/acl.module	2008-03-18 18:14:07.187500000 +0530
@@ -13,9 +13,9 @@
 /**
  * Create a new ACL.
  */
-function acl_create_new_acl($module, $name) {
+function acl_create_new_acl($module, $name, $priorty = 0) {
   $acl_id = db_next_id('{acl}_acl_id');
-  db_query("INSERT INTO {acl} (acl_id, module, name) VALUES (%d, '%s', '%s')", $acl_id, $module, $name);
+  db_query("INSERT INTO {acl} (acl_id, module, name, priority) VALUES (%d, '%s', '%s', %d)", $acl_id, $module, $name, $priorty);
   return $acl_id;
 }
 
