[ 
https://issues.apache.org/jira/browse/TS-4775?focusedWorklogId=26934&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-26934
 ]

ASF GitHub Bot logged work on TS-4775:
--------------------------------------

                Author: ASF GitHub Bot
            Created on: 23/Aug/16 15:06
            Start Date: 23/Aug/16 15:06
    Worklog Time Spent: 10m 
      Work Description: Github user jpeach commented on a diff in the pull 
request:

    https://github.com/apache/trafficserver/pull/904#discussion_r75885956
  
    --- Diff: lib/ts/InkErrno.cc ---
    @@ -0,0 +1,106 @@
    +/** @file
    +
    +  Error code defines
    +
    +  @section license License
    +
    +  Licensed to the Apache Software Foundation (ASF) under one
    +  or more contributor license agreements.  See the NOTICE file
    +  distributed with this work for additional information
    +  regarding copyright ownership.  The ASF licenses this file
    +  to you under the Apache License, Version 2.0 (the
    +  "License"); you may not use this file except in compliance
    +  with the License.  You may obtain a copy of the License at
    +
    +      http://www.apache.org/licenses/LICENSE-2.0
    +
    +  Unless required by applicable law or agreed to in writing, software
    +  distributed under the License is distributed on an "AS IS" BASIS,
    +  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    +  See the License for the specific language governing permissions and
    +  limitations under the License.
    +*/
    +
    +#include "InkErrno.h"
    +#include <string.h>
    +
    +const char *
    +InkStrerror(int ink_errno)
    +{
    +  if (ink_errno < INK_START_ERRNO) {
    +    return strerror(ink_errno);
    --- End diff --
    
    ``strerror`` is not threadsafe in glibc, however when you give it a legit 
``errno`` it returns a pointer into ``sys_errlist``, which means it works in 
the 99% case. If you pass junk it will format into a shared buffer.


Issue Time Tracking
-------------------

    Worklog Id:     (was: 26934)
    Time Spent: 1h  (was: 50m)

> Better cache error debugging.
> -----------------------------
>
>                 Key: TS-4775
>                 URL: https://issues.apache.org/jira/browse/TS-4775
>             Project: Traffic Server
>          Issue Type: Bug
>          Components: Core
>            Reporter: James Peach
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> In {{HttpSM::state_cache_open_read}} log a better error when a cache read 
> fails.



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

Reply via email to