fix: Don't create . or .. in the untar example
This commit is contained in:
parent
cd0c5df5f5
commit
6b1b8fef55
@ -88,6 +88,7 @@ int main(int argc, char** argv)
|
|||||||
{
|
{
|
||||||
if (entry.metadata.type == MTAR_DIRECTORY)
|
if (entry.metadata.type == MTAR_DIRECTORY)
|
||||||
{
|
{
|
||||||
|
if (!strcmp(entry.metadata.name, ".") || !strcmp(entry.metadata.name, "..")) continue;
|
||||||
int status = untar_directory(&entry);
|
int status = untar_directory(&entry);
|
||||||
if (status != 0)
|
if (status != 0)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user