ZIP extraction helpers.
More...
#include <stddef.h>
#include <unistd.h>
Go to the source code of this file.
|
| int | extract_zip (const char *, const char *, char *, size_t) |
| | Extract ZIP content safely into output directory.
|
ZIP extraction helpers.
- Author
- ZouariOmar zouar.nosp@m.ioma.nosp@m.r20@g.nosp@m.mail.nosp@m..com
- Version
- 0.2
- Date
- 2026-03-18
- Copyright
- Copyright (c) 2025
crun_zip_manager.h
◆ MKDIR
◆ PATH_SEP
◆ extract_zip()
| int extract_zip |
( |
const char * | zip_path, |
|
|
const char * | out_dir, |
|
|
char * | init_script_path, |
|
|
size_t | init_script_path_size ) |
Extract ZIP content safely into output directory.
Detects init script path (__init__.sh or __init__.bat) while extracting.
- Parameters
-
| zip_path | Source zip file path. |
| out_dir | Destination extraction directory. |
| init_script_path | Optional output buffer to receive detected init script path. |
| init_script_path_size | Size of init_script_path buffer. |
- Returns
- int EXIT_SUCCESS on success, EXIT_FAILURE otherwise.