Subversion Repositories filter_foundry

Rev

Rev 373 | Rev 385 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 373 Rev 381
Line 254... Line 254...
254
                                                                val = val2;
254
                                                                val = val2;
255
                                                        }
255
                                                        }
256
                                                }
256
                                                }
257
                                                if (strlen(val) >= sizeof(gdata->parm.formula[i])) {
257
                                                if (strlen(val) >= sizeof(gdata->parm.formula[i])) {
258
                                                        if (i == 0) {
258
                                                        if (i == 0) {
259
                                                                simplealert("Attention! The formula for channel I/R was too long (longer than 1023 characters) and was truncated.");
259
                                                                simplealert(_strdup("Attention! The formula for channel I/R was too long (longer than 1023 characters) and was truncated."));
260
                                                        }
260
                                                        }
261
                                                        else if (i == 1) {
261
                                                        else if (i == 1) {
262
                                                                simplealert("Attention! The formula for channel G was too long (longer than 1023 characters) and was truncated.");
262
                                                                simplealert(_strdup("Attention! The formula for channel G was too long (longer than 1023 characters) and was truncated."));
263
                                                        }
263
                                                        }
264
                                                        else if (i == 2) {
264
                                                        else if (i == 2) {
265
                                                                simplealert("Attention! The formula for channel B was too long (longer than 1023 characters) and was truncated.");
265
                                                                simplealert(_strdup("Attention! The formula for channel B was too long (longer than 1023 characters) and was truncated."));
266
                                                        }
266
                                                        }
267
                                                        else if (i == 3) {
267
                                                        else if (i == 3) {
268
                                                                simplealert("Attention! The formula for channel A was too long (longer than 1023 characters) and was truncated.");
268
                                                                simplealert(_strdup("Attention! The formula for channel A was too long (longer than 1023 characters) and was truncated."));
269
                                                        }
269
                                                        }
270
                                                        // C++ wrong warning: Buffer overflow (C6386)
270
                                                        // C++ wrong warning: Buffer overflow (C6386)
271
                                                        #pragma warning(suppress : 6386)
271
                                                        #pragma warning(suppress : 6386)
272
                                                        val[sizeof(gdata->parm.formula[i]) - 1] = '\0';
272
                                                        val[sizeof(gdata->parm.formula[i]) - 1] = '\0';
273
                                                }
273
                                                }