summaryrefslogtreecommitdiffstats
path: root/backend_kodak1400.c
diff options
context:
space:
mode:
authorSolomon Peachy <pizza@shaftnet.org>2014-02-11 22:45:14 -0500
committerSolomon Peachy <pizza@shaftnet.org>2014-02-11 22:45:14 -0500
commit523cd8e1214bba6e497262899d7bbdfc63c9b6d4 (patch)
treedb9008bf330ec7aad469fd13eebb478b9ea89af1 /backend_kodak1400.c
parent2ac2de416516125836488f999025fd39d2a880fb (diff)
downloadselphy_print-523cd8e1214bba6e497262899d7bbdfc63c9b6d4.tar.gz
selphy_print-523cd8e1214bba6e497262899d7bbdfc63c9b6d4.tar.bz2
selphy_print-523cd8e1214bba6e497262899d7bbdfc63c9b6d4.zip
backends: Revamp cmdline args so you can specify multiple backend args at once.
Diffstat (limited to 'backend_kodak1400.c')
-rw-r--r--backend_kodak1400.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/backend_kodak1400.c b/backend_kodak1400.c
index c0806a6..2472528 100644
--- a/backend_kodak1400.c
+++ b/backend_kodak1400.c
@@ -251,7 +251,7 @@ static void kodak1400_cmdline(void)
int kodak1400_cmdline_arg(void *vctx, int argc, char **argv)
{
struct kodak1400_ctx *ctx = vctx;
- int i;
+ int i, j = 0;
/* Reset arg parsing */
optind = 1;
@@ -259,13 +259,16 @@ int kodak1400_cmdline_arg(void *vctx, int argc, char **argv)
while ((i = getopt(argc, argv, "C:")) >= 0) {
switch(i) {
case 'C':
- if (ctx)
- return kodak1400_set_tonecurve(ctx, optarg);
- else
- return 1;
+ if (ctx) {
+ j = kodak1400_set_tonecurve(ctx, optarg);
+ break;
+ }
+ return 1;
default:
break; /* Ignore completely */
}
+
+ if (j) return j;
}
return 0;
@@ -593,7 +596,7 @@ top:
struct dyesub_backend kodak1400_backend = {
.name = "Kodak 1400/805",
- .version = "0.30",
+ .version = "0.31",
.uri_prefix = "kodak1400",
.cmdline_usage = kodak1400_cmdline,
.cmdline_arg = kodak1400_cmdline_arg,