You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficserver.apache.org by "Susan Hinrichs (JIRA)" <ji...@apache.org> on 2014/11/07 22:12:35 UTC

[jira] [Updated] (TS-3155) Add a value test method to the MIMEField class

     [ https://issues.apache.org/jira/browse/TS-3155?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Susan Hinrichs updated TS-3155:
-------------------------------
    Attachment: ts-3155.patch

> Add a value test method to the MIMEField class
> ----------------------------------------------
>
>                 Key: TS-3155
>                 URL: https://issues.apache.org/jira/browse/TS-3155
>             Project: Traffic Server
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Susan Hinrichs
>            Assignee: Susan Hinrichs
>             Fix For: 5.2.0
>
>         Attachments: ts-3155.patch
>
>
> In some cases, you don't need to directly manipulate the strings of values in a mime field.  But you do need to test if a mime field contains a value (e.g. does the Connection field contain the value "close").
> Currently, you must call MIMEField::value_get, but that does a bunch of copies and string allocation which is not needed in our case.  We propose adding a MIMEField::value_get_index method which returns the index of the value in the list if it is present and -1 otherwise.  Will still need to do the string parsing, but do not need to do the copies and allocation.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)