Switch to unified view

a/src/utils/appformime.cpp b/src/utils/appformime.cpp
...
...
174
174
175
#else // TEST_APPFORMIME
175
#else // TEST_APPFORMIME
176
176
177
#include <stdio.h>
177
#include <stdio.h>
178
#include <stdlib.h>
178
#include <stdlib.h>
179
#include <unistd.h>
180
#include <errno.h>
179
#include <errno.h>
181
#include <string.h>
180
#include <string.h>
182
181
183
#include <string>
182
#include <string>
184
#include <iostream>
183
#include <iostream>
...
...
210
209
211
  string reason;
210
  string reason;
212
  vector<DesktopDb::AppDef> appdefs;
211
  vector<DesktopDb::AppDef> appdefs;
213
  DesktopDb *ddb = DesktopDb::getDb();
212
  DesktopDb *ddb = DesktopDb::getDb();
214
  if (ddb == 0) {
213
  if (ddb == 0) {
215
      cerr << "Could not initialize desktop db: " << DesktopDb::getReason()
214
      cerr << "Could not create desktop db\n";
216
           << endl;
217
      exit(1);
215
      exit(1);
218
  }
216
  }
219
  if (!ddb->appForMime(mime, &appdefs, &reason)) {
217
  if (!ddb->appForMime(mime, &appdefs, &reason)) {
220
      cerr << "appForMime failed: " << reason << endl;
218
      cerr << "appForMime failed: " << reason << endl;
221
      exit(1);
219
      exit(1);