Commit b9266642 authored by claes's avatar claes

*** empty log message ***

parent 10b95544
...@@ -14,3 +14,4 @@ type <invalid type> /error ...@@ -14,3 +14,4 @@ type <invalid type> /error
ivtime <invalid time> /error ivtime <invalid time> /error
ivdtime <invalid delta time> /error ivdtime <invalid delta time> /error
negtime <negative time> /info negtime <negative time> /info
clkchange <clock has changed> /info
...@@ -28,7 +28,7 @@ nosubgraph <Subgraph not found> /error ...@@ -28,7 +28,7 @@ nosubgraph <Subgraph not found> /error
javac <Java compilation errors> /error javac <Java compilation errors> /error
nofile <File not found> /error nofile <File not found> /error
nosize <Size not found> /error nosize <Size not found> /error
no_propagate <Don't propagate event handling> /info
......
...@@ -29,6 +29,7 @@ notraceattr <No trace attribute for this class> /error ...@@ -29,6 +29,7 @@ notraceattr <No trace attribute for this class> /error
input_syntax <Input syntax> /error input_syntax <Input syntax> /error
objnotfound <Object is not found> /error objnotfound <Object is not found> /error
stringtolong <String is too long> /error stringtolong <String is too long> /error
fastconfig <Error in fast configuration> /error
......
...@@ -101,6 +101,7 @@ pasteincon <paste inconsistency> /error ...@@ -101,6 +101,7 @@ pasteincon <paste inconsistency> /error
memincon <buffer inconsistency> /error memincon <buffer inconsistency> /error
access <no such access for this configuration> /error access <no such access for this configuration> /error
attrconv <attribute conversion error> /error attrconv <attribute conversion error> /error
nosuchfile <no such file> /error
......
...@@ -783,7 +783,7 @@ int Admin::user_properties( admin_eDiaUserFunction function, int username_edit, ...@@ -783,7 +783,7 @@ int Admin::user_properties( admin_eDiaUserFunction function, int username_edit,
char system_name[80]; char system_name[80];
((AdminNav *)adminnav)->gu->get_system_name( item->group, system_name); ((AdminNav *)adminnav)->gu->get_system_name( item->group, system_name);
adminuser_setup( "User properties", username_edit, password_edit, adminuser_setup( "New User", username_edit, password_edit,
system_edit, priv_edit, "", system_name, 0); system_edit, priv_edit, "", system_name, 0);
diauser_function = admin_eDiaUserFunction_New; diauser_function = admin_eDiaUserFunction_New;
...@@ -853,7 +853,7 @@ int Admin::system_properties( admin_eDiaSysFunction function, int systemname_edi ...@@ -853,7 +853,7 @@ int Admin::system_properties( admin_eDiaSysFunction function, int systemname_edi
else else
strcpy( system_name, ""); strcpy( system_name, "");
adminsys_setup( "System group properties", systemname_edit, attr_edit, system_name, 0); adminsys_setup( "New System Group", systemname_edit, attr_edit, system_name, 0);
diasys_function = admin_eDiaSysFunction_New; diasys_function = admin_eDiaSysFunction_New;
XtManageChild( adminsys_dia); XtManageChild( adminsys_dia);
......
...@@ -4131,6 +4131,7 @@ int vldh_node_update_spec ( ...@@ -4131,6 +4131,7 @@ int vldh_node_update_spec (
else if ( node->ln.classid == vldh_class( ldhses, VLDH_CLASS_SHOWPLCATTR)) else if ( node->ln.classid == vldh_class( ldhses, VLDH_CLASS_SHOWPLCATTR))
{ {
pwr_tObjid volume_objid; pwr_tObjid volume_objid;
pwr_tObjid *thread_objid;
volume_objid.oix = 0; volume_objid.oix = 0;
volume_objid.vid = node->ln.object_did.vid; volume_objid.vid = node->ln.object_did.vid;
...@@ -4144,9 +4145,19 @@ int vldh_node_update_spec ( ...@@ -4144,9 +4145,19 @@ int vldh_node_update_spec (
sts = ldh_GetObjectPar( ldhses, sts = ldh_GetObjectPar( ldhses,
plc->lp.objdid, plc->lp.objdid,
"DevBody", "RtBody",
"ThreadObject",
(char **)&thread_objid, &size);
if ( EVEN(sts)) return sts;
if ( cdh_ObjidIsNotNull( *thread_objid)) {
sts = ldh_GetObjectPar( ldhses,
*thread_objid,
"RtBody",
"ScanTime", "ScanTime",
(char **)&time_ptr, &size); (char **)&time_ptr, &size);
}
free((char *) thread_objid);
if ( ODD(sts)) {
sts = ldh_SetObjectPar( ldhses, sts = ldh_SetObjectPar( ldhses,
node->ln.object_did, node->ln.object_did,
"DevBody", "DevBody",
...@@ -4154,6 +4165,7 @@ int vldh_node_update_spec ( ...@@ -4154,6 +4165,7 @@ int vldh_node_update_spec (
(char *)time_ptr, size); (char *)time_ptr, size);
if ( EVEN(sts)) return sts; if ( EVEN(sts)) return sts;
free((char *) time_ptr); free((char *) time_ptr);
}
sts = ldh_GetObjectPar( ldhses, sts = ldh_GetObjectPar( ldhses,
plc->lp.objdid, plc->lp.objdid,
...@@ -4539,6 +4551,7 @@ int vldh_node_create_spec ( ...@@ -4539,6 +4551,7 @@ int vldh_node_create_spec (
else if ( node->ln.classid == vldh_class( ldhses, VLDH_CLASS_SHOWPLCATTR)) else if ( node->ln.classid == vldh_class( ldhses, VLDH_CLASS_SHOWPLCATTR))
{ {
pwr_tObjid volume_objid; pwr_tObjid volume_objid;
pwr_tObjid *thread_objid;
volume_objid.oix = 0; volume_objid.oix = 0;
volume_objid.vid = node->ln.object_did.vid; volume_objid.vid = node->ln.object_did.vid;
...@@ -4552,9 +4565,19 @@ int vldh_node_create_spec ( ...@@ -4552,9 +4565,19 @@ int vldh_node_create_spec (
sts = ldh_GetObjectPar( ldhses, sts = ldh_GetObjectPar( ldhses,
plc->lp.objdid, plc->lp.objdid,
"DevBody", "RtBody",
"ThreadObject",
(char **)&thread_objid, &size);
if ( EVEN(sts)) return sts;
if ( cdh_ObjidIsNotNull( *thread_objid)) {
sts = ldh_GetObjectPar( ldhses,
*thread_objid,
"RtBody",
"ScanTime", "ScanTime",
(char **)&time_ptr, &size); (char **)&time_ptr, &size);
}
free((char *) thread_objid);
if ( ODD(sts)) {
sts = ldh_SetObjectPar( ldhses, sts = ldh_SetObjectPar( ldhses,
node->ln.object_did, node->ln.object_did,
"DevBody", "DevBody",
...@@ -4562,6 +4585,7 @@ int vldh_node_create_spec ( ...@@ -4562,6 +4585,7 @@ int vldh_node_create_spec (
(char *)time_ptr, size); (char *)time_ptr, size);
if ( EVEN(sts)) return sts; if ( EVEN(sts)) return sts;
free((char *) time_ptr); free((char *) time_ptr);
}
sts = ldh_GetObjectPar( ldhses, sts = ldh_GetObjectPar( ldhses,
plc->lp.objdid, plc->lp.objdid,
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
#include "wb_vrepdb.h" #include "wb_vrepdb.h"
#include "wb_orepdb.h" #include "wb_orepdb.h"
#include "wb_erep.h" #include "wb_erep.h"
#include "wb_dbs.h"
#include "db_cxx.h" #include "db_cxx.h"
#include "wb_ldh.h" #include "wb_ldh.h"
...@@ -107,7 +108,18 @@ bool wb_vrepdb::isLocal(const wb_orep *o) ...@@ -107,7 +108,18 @@ bool wb_vrepdb::isLocal(const wb_orep *o)
bool wb_vrepdb::createSnapshot(const char *fileName) bool wb_vrepdb::createSnapshot(const char *fileName)
{ {
try {
wb_dbs dbs(this);
if ( fileName)
dbs.setFileName( fileName);
dbs.importVolume(*this);
return true;
} catch (wb_error& e) {
return false; return false;
}
} }
void wb_vrepdb::objectName(const wb_orep *o, char *str) void wb_vrepdb::objectName(const wb_orep *o, char *str)
......
...@@ -274,6 +274,16 @@ int wb_vrepwbl::load( const char *fname) ...@@ -274,6 +274,16 @@ int wb_vrepwbl::load( const char *fname)
root_object->postBuild(); root_object->postBuild();
} }
// info(); // info();
if ( !file_cnt) {
MsgWindow::message( 'F', "No file found, ", fname);
return LDH__NOSUCHFILE;
}
if ( strcmp( volume_name, "") == 0) {
MsgWindow::message( 'F', "No volume found, ", fname);
error_cnt++;
}
if ( error_cnt || wblparser_error_cnt) { if ( error_cnt || wblparser_error_cnt) {
char str[80]; char str[80];
sprintf( str, "Errors when loading volume: %d errors found", error_cnt + wblparser_error_cnt); sprintf( str, "Errors when loading volume: %d errors found", error_cnt + wblparser_error_cnt);
......
...@@ -9,7 +9,6 @@ ...@@ -9,7 +9,6 @@
#include <string.h> #include <string.h>
#include <stdlib.h> #include <stdlib.h>
#include "wb_foe_macros.h"
#include <Xm/Xm.h> #include <Xm/Xm.h>
#include <Xm/Text.h> #include <Xm/Text.h>
...@@ -18,16 +17,18 @@ ...@@ -18,16 +17,18 @@
#include <X11/Intrinsic.h> #include <X11/Intrinsic.h>
#include <Xm/MessageB.h> #include <Xm/MessageB.h>
#include "rt_load.h"
#include "flow.h" #include "flow.h"
#include "flow_ctx.h" #include "flow_ctx.h"
#include "flow_api.h" #include "flow_api.h"
#include "flow_browctx.h" #include "flow_browctx.h"
#include "flow_browapi.h" #include "flow_browapi.h"
#include "wb_foe_macros.h"
extern "C" { extern "C" {
#include "pwr.h" #include "pwr.h"
#include "pwr_systemclasses.h" #include "pwr_systemclasses.h"
#include "rt_load.h"
#include "co_cdh.h" #include "co_cdh.h"
#include "co_dcli.h" #include "co_dcli.h"
#include "wb.h" #include "wb.h"
...@@ -703,19 +704,19 @@ pwr_tStatus WVsel::check_volumelist( ...@@ -703,19 +704,19 @@ pwr_tStatus WVsel::check_volumelist(
switch( classid) switch( classid)
{ {
case pwr_eClass_RootVolume : case pwr_eClass_RootVolume :
if ( strcmp( volumelist_ptr->p2, "RootVolume")) if ( strcmp( volumelist_ptr->p1, "RootVolume"))
class_error = 1; class_error = 1;
break; break;
case pwr_eClass_SubVolume : case pwr_eClass_SubVolume :
if ( strcmp( volumelist_ptr->p2, "SubVolume")) if ( strcmp( volumelist_ptr->p1, "SubVolume"))
class_error = 1; class_error = 1;
break; break;
case pwr_eClass_ClassVolume : case pwr_eClass_ClassVolume :
if ( strcmp( volumelist_ptr->p2, "ClassVolume")) if ( strcmp( volumelist_ptr->p1, "ClassVolume"))
class_error = 1; class_error = 1;
break; break;
case pwr_eClass_SharedVolume : case pwr_eClass_SharedVolume :
if ( strcmp( volumelist_ptr->p2, "SharedVolume")) if ( strcmp( volumelist_ptr->p1, "SharedVolume"))
class_error = 1; class_error = 1;
break; break;
} }
...@@ -725,7 +726,7 @@ pwr_tStatus WVsel::check_volumelist( ...@@ -725,7 +726,7 @@ pwr_tStatus WVsel::check_volumelist(
{ {
errlen += sprintf( &errstr[errlen], errlen += sprintf( &errstr[errlen],
"** Error, Volume %s is configured with another class '%s'\n", "** Error, Volume %s is configured with another class '%s'\n",
name, volumelist_ptr->p2); name, volumelist_ptr->p1);
MsgWindow::message( 'E', &errstr[errlen_old], msgw_ePop_No); MsgWindow::message( 'E', &errstr[errlen_old], msgw_ePop_No);
errlen_old = errlen; errlen_old = errlen;
BEEP; BEEP;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment