Commit 0cd79024 authored by claes's avatar claes

Rack-objects without methods were not allowed

parent 83a65347
/*
* Proview $Id: rt_io_base.c,v 1.23 2007-05-18 12:05:12 claes Exp $
* Proview $Id: rt_io_base.c,v 1.24 2007-10-01 14:39:38 claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
......@@ -1495,7 +1495,7 @@ static pwr_tStatus io_init_card(
}
if ( ok) {
/* Tread this card in this process */
/* Treat this card in this process */
strcpy( attrname, cname);
strcat( attrname, ".MaxNoOfChannels");
sts = gdh_GetObjectInfo( attrname, &maxchan, sizeof(maxchan));
......@@ -1934,10 +1934,10 @@ static pwr_tStatus io_init_rack(
}
if ( io_CheckClassIoType( io_eType_Rack, class)) {
sts = io_FindMethods( class, io_eType_Rack, &RackInit, &RackClose, &RackRead, &RackWrite, &RackSwap);
if ( ODD(sts)) {
if ( RackInit != NULL || RackClose != NULL || RackRead != NULL || RackWrite != NULL || RackSwap != NULL) {
/* This is a rack object, */
sts = io_FindMethods( class, io_eType_Rack, &RackInit, &RackClose, &RackRead, &RackWrite, &RackSwap);
/* Check if the rack should be handled by this process */
sts = gdh_ObjidToName( objid, rname, sizeof(rname),
......@@ -2025,8 +2025,6 @@ static pwr_tStatus io_init_rack(
}
return IO__TRV_NEXT;
}
}
}
return IO__SUCCESS;
}
......
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