### Eclipse Workspace Patch 1.0
#P d6-multisite
Index: public_html/sites/all/modules/contrib/install_profile_api/core/filter.inc
===================================================================
--- public_html/sites/all/modules/contrib/install_profile_api/core/filter.inc	(revision 8331)
+++ public_html/sites/all/modules/contrib/install_profile_api/core/filter.inc	(working copy)
@@ -23,14 +23,8 @@
  *   If this format is cacheable.
  */
 function install_add_format($name, $cache = 1) {
-  $format_id = db_next_id('{filter_formats}_fid');
-  // Check explicitly for format_id <= 3. If the database was improperly prefixed,
-  // this would cause a nasty infinite loop or duplicate mid errors.
-  // TODO: have automatic prefixing through an installer to prevent this.
-  while ($format_id <= 3) {
-    $format_id = db_next_id('{filter_formats}_fid');
-  }
-  db_query("INSERT INTO {filter_formats} (`format`, `name`, `roles`, `cache`) VALUES (%d, '%s', '', %d)", $format_id, $name, $cache);
+  db_query("INSERT INTO {filter_formats} (name, roles, cache) VALUES ('%s', '', %d)", $name, $cache);
+  $format_id = db_last_insert_id('filter_formats', 'format');
   return $format_id;
 }
 
