]> rtime.felk.cvut.cz Git - frescor/forb.git/commitdiff
Added error checking of deserialization in skeletons
authorMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 21 May 2009 11:10:56 +0000 (13:10 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Thu, 21 May 2009 11:10:56 +0000 (13:10 +0200)
TODO
forb-idl/forb-idl-c-skels.c

diff --git a/TODO b/TODO
index bf1e9f9d958b78cb60ab2cfcb731c5ac1ebb4322..8c14cc8191ddccea3beddede1d283ec3dd5a34a1 100644 (file)
--- a/TODO
+++ b/TODO
@@ -3,8 +3,6 @@
 * More flexible handling of log messages (dynamic registration,
    parsing of command line parameters).
 
-* Error checking of deserialization in skeletons
-
 * Add FNA as transport protocol (probably with some reliable protocol
    on top of FNA)
 
index 12bd67471046f0e9e5d886c5fb79b802ecaa5aad..1d353381e186063ebbb45c5c500effff1a711774 100644 (file)
@@ -316,10 +316,10 @@ static void ck_output_op_skel(IDL_tree op, char *intf_id, OIDL_Run_Info *rinfo,
                role = oidl_attr_to_paramrole(IDL_PARAM_DCL(parm).attr);
                if (role == DATA_IN || role == DATA_INOUT) {
                        char *name = IDL_IDENT(IDL_PARAM_DCL(parm).simple_declarator).str;
-                       fprintf(ci->fh, /* "  r = " */ "    ");
+                       fprintf(ci->fh, "    if (!");
                        forb_cbe_write_typespec(ci->fh, IDL_PARAM_DCL(parm).param_type_spec);
-                       fprintf(ci->fh, "_deserialize(cin, &%s);\n", name);
-/*                     fprintf(ci->fh, "    if (!r) { ev->major = FORB_EX_IMP_LIMIT; goto exception; }\n"); */
+                       fprintf(ci->fh, "_deserialize(cin, &%s)) {\n", name);
+                       fprintf(ci->fh, "      env->major = FORB_EX_MARSHAL; goto exception;\n    }\n");
                }
        }