~ubuntu-branches/ubuntu/lucid/libexif/lucid

« back to all changes in this revision

Viewing changes to libexif/pentax/mnote-pentax-entry.c

  • Committer: Bazaar Package Importer
  • Author(s): Emmanuel Bouthenot
  • Date: 2009-04-19 17:53:15 UTC
  • mfrom: (6.1.1 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090419175315-5aiwj7jbm26srabc
Tags: 0.6.17-1
* Adopt the package within pkg-phototools:
  - Set the Maintainer to the group
  - Add Frederic Peters and myself as Uploaders.
  - Add Vcs-Browser and Vcs-Git fields accordingly.
* New upstream release:
  - remove patches merged upsteam:
    + 30_olympus_makernote.dpatch
    + 40_crash_looking_up_invalid_values.dpatch
    + 50_relibtoolize.dpatch
    + CVE-2007-6351.dpatch
    + CVE-2007-6352.dpatch
  - convert existing patches from dpatch to quilt.
  - Fix a bug while reading exif datas in some cases (Closes: #447907)
* Switch packaging to debhelper 7
* Update debian/control:
  - Drop duplicate section field for exif12
  - Bump Standards-Version to 3.8.1
  - Replace deprecated ${Source-Version} by ${binary:Version}
  - Enhance libexif-dev long description.
  - Add homepage field.
  - Add DM-Upload-Allowed field.
* Force remove of files not fully cleaned
* Remove empty doc files in libexif-dev.
* Update debian/copyright.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* mnote-pentax-entry.c
2
2
 *
3
 
 * Copyright � 2002 Lutz M�ller <lutz@users.sourceforge.net>
 
3
 * Copyright (c) 2002 Lutz Mueller <lutz@users.sourceforge.net>
4
4
 *
5
5
 * This library is free software; you can redistribute it and/or
6
6
 * modify it under the terms of the GNU Lesser General Public
65
65
        }                                                               \
66
66
}
67
67
 
68
 
static struct {
 
68
static const struct {
69
69
        ExifTag tag;
70
70
        struct {
71
71
                int index;
72
72
                const char *string;
73
73
        } elem[33];
74
74
} items[] = {
 
75
#ifndef NO_VERBOSE_TAG_DATA
75
76
  { MNOTE_PENTAX_TAG_MODE,
76
77
    { {0, N_("Auto")},
77
78
      {1, N_("Night-scene")},
259
260
    { {0, N_("Off")},
260
261
      {1, N_("On")},
261
262
      {0, NULL}}},
 
263
#endif
262
264
  {0, {{0, NULL}}}
263
265
};
264
266
 
265
267
/* Two-component values */
266
 
static struct {
 
268
static const struct {
267
269
        ExifTag tag;
268
270
        struct {
269
271
                int index1, index2;
270
272
                const char *string;
271
273
        } elem[39];
272
274
} items2[] = {
 
275
#ifndef NO_VERBOSE_TAG_DATA
273
276
  { MNOTE_PENTAX2_TAG_IMAGE_SIZE,
274
277
    { {0, 0, "2304x1728"},
275
278
      {4, 0, "1600x1200"},
276
279
      {5, 0, "2048x1536"},
277
280
      {8, 0, "2560x1920"},
 
281
      {34, 0, "1536x1024"},
278
282
      {36, 0, N_("3008x2008 or 3040x2024")},
279
283
      {37, 0, "3008x2000"},
280
284
      {35, 1, "2400x1600"},
296
300
      {5,   2, N_("Portrait")},
297
301
      {6,   2, N_("Landscape")},
298
302
      {0,   0, NULL}}},
 
303
#endif
299
304
  {0, {{0, 0, NULL}}}
300
305
};
301
306
 
341
346
                        /* search the tag */
342
347
                        for (i = 0; (items[i].tag && items[i].tag != entry->tag); i++);
343
348
                        if (!items[i].tag) {
344
 
                                strncpy (val, _("Internal error"), maxlen);
 
349
                                snprintf (val, maxlen,
 
350
                                          _("Internal error (unknown value %i)"), vs);
345
351
                                break;
346
352
                        }
347
353
 
353
359
                                          _("Internal error (unknown value %i)"), vs);
354
360
                                break;
355
361
                        }
356
 
                        strncpy (val, items[i].elem[j].string, maxlen);
 
362
                        strncpy (val, _(items[i].elem[j].string), maxlen);
357
363
                } else {
358
364
                        /* Two-component values */
359
365
                        CF (entry->format, EXIF_FORMAT_SHORT, val, maxlen);
364
370
                        /* search the tag */
365
371
                        for (i = 0; (items2[i].tag && items2[i].tag != entry->tag); i++);
366
372
                        if (!items2[i].tag) {
367
 
                                strncpy (val, _("Internal error"), maxlen);
 
373
                                snprintf (val, maxlen,
 
374
                                          _("Internal error (unknown value %i %i)"), vs, vs2);
368
375
                                break;
369
376
                        }
370
377
 
376
383
                                          _("Internal error (unknown value %i %i)"), vs, vs2);
377
384
                                break;
378
385
                        }
379
 
                        strncpy (val, items2[i].elem[j].string, maxlen);
 
386
                        strncpy (val, _(items2[i].elem[j].string), maxlen);
380
387
                }
381
388
                break;
382
389