Ack from me. Best regards, Zoran
-----Original Message----- From: [email protected] [mailto:[email protected]] Sent: den 15 september 2014 12:09 To: Anders Björnerstedt; Zoran Milinkovic Cc: [email protected] Subject: [PATCH 1 of 1] imm: Return INVALID_PARAM if the Operation name is not present in resourceDisplay [ #1062] osaf/services/saf/immsv/immnd/ImmModel.cc | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) The opName is checked at immnd, if it fails INVALID_PARAM is returned before passing the function to ImmModel::resourceDisplay. In general OPname will not be passed as NULL to ImmModel::resourceDisplay. But, it is good to have the check at ImmModel::resourceDisplay. diff --git a/osaf/services/saf/immsv/immnd/ImmModel.cc b/osaf/services/saf/immsv/immnd/ImmModel.cc --- a/osaf/services/saf/immsv/immnd/ImmModel.cc +++ b/osaf/services/saf/immsv/immnd/ImmModel.cc @@ -11173,6 +11173,13 @@ ImmModel::resourceDisplay(const struct I goto done; } } + } else { + LOG_WA("The Operation name is not present in the requested parameters for displaying IMM resources"); + err = SA_AIS_ERR_INVALID_PARAM; + int len= strlen("Operation name is not present in the requested parameters")+1; + errStr = (SaStringT)malloc (len); + strcpy(errStr, "Operation name is not present in the requested parameters"); + goto done; } if ((strcmp(opName,"display")==0)) { ------------------------------------------------------------------------------ Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk _______________________________________________ Opensaf-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opensaf-devel
