[sr-dev] [tracker] Comment added: textops: add functions to convert and append multipart bodies.

sip-router bugtracker at sip-router.org
Mon Apr 28 23:11:28 CEST 2014


THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.

The following task has a new comment added:

FS#410 - textops: add functions to convert and append multipart bodies.
User who did this - Daniel-Constantin Mierla (miconda)

----------
First patch can be applied. You should do it soon as I have another flag to add in the very near future.

Second patch:
- license has to be bsd, being contribution to core
- has leaks - you have to allocate after you check the parameters. In case of errors, free the previous allocated pointers
- you don't check if result->s allocation returns valid pointer or null
- does it really need to allocate the str*? Shouldn't work with allocating the (str*)->s? The output can be a parameter instead of returned pointer, or eventually a static str variable inside the function. I see append_str() is used twice in the 3rd patch, returned pointer being always freed.

Third patch:
- not completely reviewed, but
- fb and ob are set via append_str(), but only fb and ob are freed, i haven't seen fb->s, ob->s being freed
- quite some number of commented logs, maybe they should removed
- aesthetics: 
   - preferable to use /**/ for commenting, // is c++ style, although most c compilers are fine with it now
   - negate expression in the first IF inside check_boundaries() -- if(msg->msg_flags&FL_BODY_MULTIPART) -- and return immediately if true to avoid useless 'clean:' operations, as most of the traffic will be without mutipart bodies.
----------

More information can be found at the following URL:
https://sip-router.org/tracker/index.php?do=details&task_id=410#comment1421

You are receiving this message because you have requested it from the Flyspray bugtracking system.  If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.



More information about the sr-dev mailing list