[tickets] [opensaf:tickets] #3070 mbc: some minor coding errors

2019-08-19 Thread Thuan via Opensaf-tickets
- **status**: review --> fixed



---

** [tickets:#3070] mbc: some minor coding errors**

**Status:** fixed
**Milestone:** 5.19.10
**Created:** Wed Aug 14, 2019 10:10 AM UTC by Thuan
**Last Updated:** Wed Aug 14, 2019 10:18 AM UTC
**Owner:** Thuan


Some minor coding errors:
static const char *disc_trace[] = {"Peer UP msg", "Peer DOWN msg",
   "Peer INFO msg", "Peer INFO resp msg",
   "Peer Role change msg"   ** // Missing comma 
" , "**
   "Invalid peer discovery msg"};
   

uint32_t mbcsv_process_snd_ckpt_request(NCS_MBCSV_ARG \*arg)
uint32t mbcsv_process_chg_role_request(NCSMBCSVARG \*arg)
uint32_t mbcsv_process_close_request(NCS_MBCSV_ARG \*arg)
~~~
if (NULL ==
(mbc_reg = (MBCSV_REG *)m_MBCSV_TAKE_HANDLE(arg->i_mbcsv_hdl))) {
TRACE_2("bad handle specified");
rc = SA_AIS_ERR_BAD_HANDLE;
// Should return here if not NULL pointer access in later code
}

m_NCS_LOCK(_reg->svc_lock, NCS_LOCK_READ);


TRACE("svc_id:%u, pwe_hdl:%u", mbc_reg->svc_id, ckpt_inst->pwe_hdl);
~~~


---

Sent from sourceforge.net because opensaf-tickets@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/opensaf/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/opensaf/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.___
Opensaf-tickets mailing list
Opensaf-tickets@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets


[tickets] [opensaf:tickets] #3069 rde: misc-suspicious-missing-comma

2019-08-19 Thread Thuan via Opensaf-tickets
- **status**: review --> fixed



---

** [tickets:#3069] rde: misc-suspicious-missing-comma**

**Status:** fixed
**Milestone:** 5.19.10
**Created:** Wed Aug 14, 2019 09:26 AM UTC by Thuan
**Last Updated:** Wed Aug 14, 2019 09:43 AM UTC
**Owner:** Thuan


const char *rde_msg_name[] = {"-",
  "RDE_MSG_PEER_UP(1)",
  "RDE_MSG_PEER_DOWN(2)",
  "RDE_MSG_PEER_INFO_REQ(3)",
  "RDE_MSG_PEER_INFO_RESP(4)",
  "RDE_MSG_NEW_ACTIVE_CALLBACK(5)"//Missing " , 
" here
  "RDE_MSG_NODE_UP(6)",
  "RDE_MSG_NODE_DOWN(7)",
  "RDE_MSG_TAKEOVER_REQUEST_CALLBACK(8)",
  "RDE_MSG_ACTIVE_PROMOTION_SUCCESS(9)",
  "RDE_MSG_CONTROLLER_UP(10)",
  "RDE_MSG_CONTROLLER_DOWN(11)"};


---

Sent from sourceforge.net because opensaf-tickets@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/opensaf/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/opensaf/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.___
Opensaf-tickets mailing list
Opensaf-tickets@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets


[tickets] [opensaf:tickets] #2770 imm: data size mismatches in pbe code

2019-08-19 Thread Thanh Nguyen via Opensaf-tickets
- **status**: assigned --> review



---

** [tickets:#2770] imm: data size mismatches in pbe code**

**Status:** review
**Milestone:** 5.19.10
**Created:** Wed Jan 24, 2018 03:42 PM UTC by Vu Minh Nguyen
**Last Updated:** Wed Jul 24, 2019 04:07 AM UTC
**Owner:** Thanh Nguyen


Object ID and Class ID are `unsigned int` data type, but they are not used 
consistently through the codes (local variables and function parameters) - few 
places use `int`.

If the values of these IDs reach over MAX_INT,  we may have problem when doing 
sqlite queries.

::: C++
static void valuesToPBE(const SaImmAttrValuesT_2 *p, SaImmAttrFlagsT 
attrFlags, int objId, void *db_handle) {}

void objectModifyDiscardMatchingValuesOfAttrToPBE(
void *db_handle, std::string objName, const SaImmAttrValuesT_2 *attrValue,
SaUint64T ccb_id) {
int object_id;
int class_id;
}

 

  


---

Sent from sourceforge.net because opensaf-tickets@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/opensaf/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/opensaf/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.___
Opensaf-tickets mailing list
Opensaf-tickets@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets


[tickets] [opensaf:tickets] #3065 smf: warnings when compiling code with clang

2019-08-19 Thread Thanh Nguyen via Opensaf-tickets
- **status**: unassigned --> review



---

** [tickets:#3065] smf: warnings when compiling code  with clang**

**Status:** review
**Milestone:** 5.19.10
**Created:** Tue Aug 06, 2019 08:01 AM UTC by Vu Minh Nguyen
**Last Updated:** Fri Aug 09, 2019 03:12 AM UTC
**Owner:** Thanh Nguyen


./src/smf/smfd/SmfUtils.h:65:20: warning: 'smf_valueToString' has C-linkage 
specified, but returns user-defined type 'std::string' (aka 
'basic_string') which is incompatible with C
  [-Wreturn-type-c-linkage]
extern std::string smf_valueToString(SaImmAttrValueT value,
   ^
./src/smf/smfd/SmfUtils.h:72:26: warning: 'smfStateToString' has C-linkage 
specified, but returns user-defined type 'const std::string' (aka 'const 
basic_string') which is incompatible with C
  [-Wreturn-type-c-linkage]
extern const std::string smfStateToString(const uint32_t& i_stateId,
 ^
src/smf/smfd/SmfUpgradeCampaign.cc:933:61: warning: adding 'int' to a 
string does not append to the string [-Wstring-plus-int]
  std::string error = "To many campaign restarts, max " + cnt;
  ~~^
src/smf/smfd/SmfUpgradeCampaign.cc:933:61: note: use array indexing to 
silence this warning
  std::string error = "To many campaign restarts, max " + cnt;
^
  & []



---

Sent from sourceforge.net because opensaf-tickets@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/opensaf/tickets/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/opensaf/admin/tickets/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.___
Opensaf-tickets mailing list
Opensaf-tickets@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets