aboutsummaryrefslogtreecommitdiffhomepage
path: root/backend.c
diff options
context:
space:
mode:
Diffstat (limited to 'backend.c')
-rw-r--r--backend.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/backend.c b/backend.c
index e9b12df..ed5e6db 100644
--- a/backend.c
+++ b/backend.c
@@ -251,8 +251,16 @@ int mm_backend_register(backend b){
int backends_start(){
int rv = 0, current;
- size_t u;
+ size_t u, p;
for(u = 0; u < nbackends; u++){
+ //only start backends that have instances
+ for(p = 0; p < ninstances && instances[p]->backend != backends + u; p++){
+ }
+ if(p == ninstances){
+ fprintf(stderr, "Skipping start of backend %s\n", backends[u].name);
+ continue;
+ }
+
current = backends[u].start();
if(current){
fprintf(stderr, "Failed to start backend %s\n", backends[u].name);