Author: mkhl Date: 2006-07-15 09:11:02 +0000 (Sat, 15 Jul 2006) New Revision: 17053
WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=17053 Log: Handle missing async step. Don't include a default case when switching ac->step, that suppresses the wrong warnings. Martin Modified: branches/SOC/mkhl/ldb-map/modules/ldb_map.c Changeset: Modified: branches/SOC/mkhl/ldb-map/modules/ldb_map.c =================================================================== --- branches/SOC/mkhl/ldb-map/modules/ldb_map.c 2006-07-15 09:07:24 UTC (rev 17052) +++ branches/SOC/mkhl/ldb-map/modules/ldb_map.c 2006-07-15 09:11:02 UTC (rev 17053) @@ -2662,15 +2662,15 @@ case MAP_DO_RENAME_FIXUP: return ac->down_req; + case MAP_SEARCH_LOCAL: case MAP_DO_ADD_LOCAL: case MAP_DO_MODIFY_LOCAL: case MAP_DO_DELETE_LOCAL: case MAP_DO_RENAME_LOCAL: return ac->local_req; + } - default: - return NULL; - } + return NULL; /* unreachable; silences a warning */ } typedef int (*map_next_function)(struct ldb_async_handle *handle); @@ -2681,6 +2681,9 @@ map_async_get_next(struct map_async_context *ac) { switch (ac->step) { + case MAP_SEARCH_LOCAL: + return NULL; + case MAP_DO_ADD_REMOTE: return map_add_do_local; @@ -2716,10 +2719,9 @@ case MAP_DO_RENAME_LOCAL: return NULL; - - default: - return NULL; } + + return NULL; /* unreachable; silences a warning */ } /* Async trampoline */
