On Fri, Apr 13, 2012 at 5:53 PM, ChunEon Park <[email protected]> wrote: > Ah! yes. it's for image format. > But if it is a buffer for image then why does it have one more space? > just curious.
It's not really needed. just addition 1. i think it can be removed > > > > ------------------------------------ > > -Regards, Hermet- > > > > > -----Original Message----- > From: "Hyoyoung Chang"<[email protected]> > To: "Enlightenment developer > list"<[email protected]>; > Cc: > Sent: 2012-04-13 (금) 14:51:33 > Subject: Re: [E-devel] question about elm_cnp_selection_set in elm_cnp > > it's image type. that means some null char can be contained in the buffer. > it's not char string so its not need to null terminated. > > On Fri, Apr 13, 2012 at 2:01 PM, Minseok Kim > <minseok3.kim>@samsung.com> wrote: > > I have a question. > > > > ----elm_cnp.c : 418 > > > ---------------------------------------------------------------------------- > > ------------------- > > > > if (format == ELM_SEL_FORMAT_IMAGE) > > { > > sel->selbuf = malloc(buflen+1); > > memcpy(sel->selbuf, selbuf, buflen); > > } > > > > > ---------------------------------------------------------------------------- > > --------------------------------------- > > > > This code allocates buffer with 'buflen+1' and copy. > > But there is no code to add last '\0' character. > > > > Is there no problem? > > I think it need to set last '\0' character(or need to use calloc) > > > > Please answer me. > > > > Thanks. > > > > > > > ------------------------------------------------------------------------------ > > For Developers, A Lot Can Happen In A Second. > > Boundary is the first to Know...and Tell You. > > Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! > > http://p.sf.net/sfu/Boundary-d2dvs2 > > _______________________________________________ > > enlightenment-devel mailing list > > [email protected] > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > > ------------------------------------------------------------------------------ > For Developers, A Lot Can Happen In A Second. > Boundary is the first to Know...and Tell You. > Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! > http://p.sf.net/sfu/Boundary-d2dvs2 > _______________________________________________ > enlightenment-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > > > ------------------------------------------------------------------------------ > For Developers, A Lot Can Happen In A Second. > Boundary is the first to Know...and Tell You. > Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! > http://p.sf.net/sfu/Boundary-d2dvs2 > _______________________________________________ > enlightenment-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel ------------------------------------------------------------------------------ For Developers, A Lot Can Happen In A Second. Boundary is the first to Know...and Tell You. Monitor Your Applications in Ultra-Fine Resolution. Try it FREE! http://p.sf.net/sfu/Boundary-d2dvs2 _______________________________________________ enlightenment-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
