Skip to content

Commit 6bb356a

Browse files
committed
Squash a bunch of harmless compiler warnings.
Signed-off-by: Jeff Squyres <jsquyres@cisco.com>
1 parent a32c589 commit 6bb356a

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

ompi/mca/coll/base/coll_base_allgatherv.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ int ompi_coll_base_allgatherv_intra_bruck(const void *sbuf, int scount,
100100
{
101101
int line = -1, err = 0, rank, size, sendto, recvfrom, distance, blockcount, i;
102102
int *new_rcounts = NULL, *new_rdispls = NULL, *new_scounts = NULL, *new_sdispls = NULL;
103-
ptrdiff_t slb, rlb, sext, rext;
103+
ptrdiff_t rlb, rext;
104104
char *tmpsend = NULL, *tmprecv = NULL;
105105
struct ompi_datatype_t *new_rdtype, *new_sdtype;
106106

@@ -226,7 +226,7 @@ int ompi_coll_base_allgatherv_intra_ring(const void *sbuf, int scount,
226226
mca_coll_base_module_t *module)
227227
{
228228
int line = -1, rank, size, sendto, recvfrom, i, recvdatafrom, senddatafrom, err = 0;
229-
ptrdiff_t slb, rlb, sext, rext;
229+
ptrdiff_t rlb, rext;
230230
char *tmpsend = NULL, *tmprecv = NULL;
231231

232232
size = ompi_comm_size(comm);
@@ -355,7 +355,7 @@ ompi_coll_base_allgatherv_intra_neighborexchange(const void *sbuf, int scount,
355355
int line = -1, rank, size, i, even_rank, err = 0;
356356
int neighbor[2], offset_at_step[2], recv_data_from[2], send_data_from;
357357
int new_scounts[2], new_sdispls[2], new_rcounts[2], new_rdispls[2];
358-
ptrdiff_t slb, rlb, sext, rext;
358+
ptrdiff_t rlb, rext;
359359
char *tmpsend = NULL, *tmprecv = NULL;
360360
struct ompi_datatype_t *new_rdtype, *new_sdtype;
361361

@@ -500,7 +500,7 @@ int ompi_coll_base_allgatherv_intra_two_procs(const void *sbuf, int scount,
500500
{
501501
int line = -1, err = 0, rank, remote;
502502
char *tmpsend = NULL, *tmprecv = NULL;
503-
ptrdiff_t sext, rext, lb;
503+
ptrdiff_t rext, lb;
504504

505505
rank = ompi_comm_rank(comm);
506506

opal/mca/btl/openib/btl_openib_component.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3719,7 +3719,7 @@ static void handle_wc(mca_btl_openib_device_t* device, const uint32_t cq,
37193719
endpoint->endpoint_state = MCA_BTL_IB_FAILED;
37203720

37213721
if(IBV_WC_SEND == wc->opcode && !BTL_OPENIB_QP_TYPE_PP(qp)) {
3722-
BTL_VERBOSE(("frag %p returning %d credits", frag, 1+n));
3722+
BTL_VERBOSE(("frag %p returning %d credits", (void*) frag, 1+n));
37233723
OPAL_THREAD_FETCH_ADD32(&openib_btl->qps[qp].u.srq_qp.sd_credits, 1+n);
37243724
/* new SRQ credit available. Try to progress pending frags*/
37253725
progress_pending_frags_srq(openib_btl, qp);

orte/mca/rmaps/base/rmaps_base_map_job.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -556,17 +556,17 @@ void orte_rmaps_base_display_map(orte_job_t *jdata)
556556
if (NULL == (proc = (orte_proc_t*)opal_pointer_array_get_item(node->procs, j))) {
557557
continue;
558558
}
559-
memset(tmp1, 0, 1024);
559+
memset(tmp1, 0, sizeof(tmp1));
560560
if (orte_get_attribute(&proc->attributes, ORTE_PROC_HWLOC_BOUND, (void**)&bd, OPAL_PTR)) {
561561
if (NULL == bd) {
562-
(void)strncpy(tmp1, "UNBOUND", strlen("UNBOUND"));
562+
(void)strncpy(tmp1, "UNBOUND", sizeof(tmp1));
563563
} else {
564564
if (OPAL_ERR_NOT_BOUND == opal_hwloc_base_cset2mapstr(tmp1, sizeof(tmp1), node->topology->topo, bd->cpuset)) {
565-
(void)strncpy(tmp1, "UNBOUND", strlen("UNBOUND"));
565+
(void)strncpy(tmp1, "UNBOUND", sizeof(tmp1));
566566
}
567567
}
568568
} else {
569-
(void)strncpy(tmp1, "UNBOUND", strlen("UNBOUND"));
569+
(void)strncpy(tmp1, "UNBOUND", sizeof(tmp1));
570570
}
571571
opal_output(orte_clean_output, "\t\t<process rank=%s app_idx=%ld local_rank=%lu node_rank=%lu binding=%s>",
572572
ORTE_VPID_PRINT(proc->name.vpid), (long)proc->app_idx,

0 commit comments

Comments
 (0)