Project

General

Profile

Actions

Bug #1166

closed

tls: CID 1197759: Resource leak (RESOURCE_LEAK)

Added by Victor Julien over 10 years ago. Updated almost 9 years ago.

Status:
Closed
Priority:
Low
Assignee:
Target version:
Affected Versions:
Effort:
Difficulty:
Label:

Description

Coverity scan of master branch:

*** CID 1197759:  Resource leak  (RESOURCE_LEAK)
/src/detect-tls-version.c: 205 in DetectTlsVersionParse()
199             } else if (strcmp("1.1", tmp_str) == 0) {
200                 temp = TLS_VERSION_11;
201             } else if (strcmp("1.2", tmp_str) == 0) {
202                 temp = TLS_VERSION_12;
203             } else {
204                 SCLogError(SC_ERR_INVALID_VALUE, "Invalid value");
>>>     CID 1197759:  Resource leak  (RESOURCE_LEAK)
>>>     Variable "orig" going out of scope leaks the storage it points to.
205                 goto error;
206             }
207     
208             tls->ver = temp;
209     
210             SCFree(orig);

Actions

Also available in: Atom PDF