summaryrefslogtreecommitdiffstats
path: root/generator
diff options
context:
space:
mode:
authorRichard W.M. Jones <rjones@redhat.com>2011-01-26 14:15:23 +0000
committerRichard W.M. Jones <rjones@redhat.com>2011-01-26 14:15:23 +0000
commit2110f6fa8c397f74e38408612d5514a42f3b9cee (patch)
treeb4212f49061bce2e333d61851a41c7817d0dbc42 /generator
parentc76f155496717c526ef0b5e72083bb0034f61d3c (diff)
downloadlibguestfs-2110f6fa8c397f74e38408612d5514a42f3b9cee.tar.gz
libguestfs-2110f6fa8c397f74e38408612d5514a42f3b9cee.tar.xz
libguestfs-2110f6fa8c397f74e38408612d5514a42f3b9cee.zip
generator: Fix generation of library-side stubs with optional String arguments.
Diffstat (limited to 'generator')
-rw-r--r--generator/generator_c.ml2
1 files changed, 1 insertions, 1 deletions
diff --git a/generator/generator_c.ml b/generator/generator_c.ml
index 0b3c8508..46ba6913 100644
--- a/generator/generator_c.ml
+++ b/generator/generator_c.ml
@@ -1047,7 +1047,7 @@ check_state (guestfs_h *g, const char *caller)
pr " else\n";
pr " args.%s = 0;\n" n
| String n ->
- pr " args.%s = (char *) %s;\n" n n;
+ pr " args.%s = (char *) optargs->%s;\n" n n;
pr " else\n";
pr " args.%s = (char *) \"\";\n" n
| _ -> assert false