Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
Sleuthkit
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IRT
Sleuthkit
Commits
7c12ba87
Unverified
Commit
7c12ba87
authored
7 years ago
by
Richard Cordovano
Committed by
GitHub
7 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #1107 from APriestman/3479_memoryLeak_issue1097
3479 fix iso9660 memory leaks
parents
298bf457
5fe19c3d
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tsk/fs/iso9660.c
+14
-0
14 additions, 0 deletions
tsk/fs/iso9660.c
with
14 additions
and
0 deletions
tsk/fs/iso9660.c
+
14
−
0
View file @
7c12ba87
...
...
@@ -507,6 +507,7 @@ iso9660_load_inodes_dir(TSK_FS_INFO * fs, TSK_OFF_T a_offs, int count,
tsk_error_set_errno
(
TSK_ERR_FS_ARG
);
tsk_error_set_errstr
(
"iso9660_load_inodes_dir: Name argument specified is too long"
);
free
(
in_node
);
return
-
1
;
}
strncpy
(
in_node
->
inode
.
fn
,
a_fn
,
ISO9660_MAXNAMLEN_STD
+
1
);
...
...
@@ -616,6 +617,7 @@ iso9660_load_inodes_dir(TSK_FS_INFO * fs, TSK_OFF_T a_offs, int count,
if
(
tsk_verbose
)
tsk_fprintf
(
stderr
,
"iso9660_load_inodes_dir: length of name after processing is 0. bailing
\n
"
);
free
(
in_node
);
break
;
}
...
...
@@ -634,6 +636,7 @@ iso9660_load_inodes_dir(TSK_FS_INFO * fs, TSK_OFF_T a_offs, int count,
tsk_fprintf
(
stderr
,
"iso9660_load_inodes_dir: file starts past end of image (%"
PRIu32
"). bailing
\n
"
,
tsk_getu32
(
fs
->
endian
,
dentry
->
ext_loc_m
));
free
(
in_node
);
break
;
}
in_node
->
offset
=
...
...
@@ -644,6 +647,7 @@ iso9660_load_inodes_dir(TSK_FS_INFO * fs, TSK_OFF_T a_offs, int count,
tsk_fprintf
(
stderr
,
"iso9660_load_inodes_dir: file ends past end of image (%"
PRIu32
" bytes). bailing
\n
"
,
tsk_getu32
(
fs
->
endian
,
in_node
->
inode
.
dr
.
data_len_m
)
+
in_node
->
offset
);
free
(
in_node
);
break
;
}
/* record size to make sure fifos show up as unique files */
...
...
@@ -676,6 +680,7 @@ iso9660_load_inodes_dir(TSK_FS_INFO * fs, TSK_OFF_T a_offs, int count,
if
(
tsk_verbose
)
tsk_fprintf
(
stderr
,
"iso9660_load_inodes_dir: parse_susp returned error (%s). bailing
\n
"
,
tsk_error_get
());
free
(
in_node
);
break
;
}
...
...
@@ -1141,6 +1146,15 @@ iso9660_close(TSK_FS_INFO * fs)
free
(
s
);
}
while
(
iso
->
in_list
!=
NULL
)
{
iso9660_inode_node
*
in
=
iso
->
in_list
;
iso
->
in_list
=
iso
->
in_list
->
next
;
if
(
in
->
inode
.
rr
!=
NULL
)
{
free
(
in
->
inode
.
rr
);
}
free
(
in
);
}
tsk_fs_free
(
fs
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment