added fsanitize params

This commit is contained in:
JOLIMAITRE Matthieu 2022-10-17 23:05:13 +02:00
parent c71feec15f
commit 6a242e1e84
4 changed files with 13 additions and 3 deletions

2
Cargo.lock generated
View file

@ -138,7 +138,7 @@ checksum = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8"
[[package]]
name = "epitls-pi"
version = "1.3.0"
version = "1.3.1"
dependencies = [
"chrono",
"clap",

View file

@ -2,7 +2,8 @@
## Description
A little helper tool meant to ease the developpment of the C piscine at EPITA/Toulouse.
A little helper tool meant to ease the developpment of the C piscine at
EPITA/Toulouse.
## Usage
@ -28,3 +29,9 @@ SUBCOMMANDS:
- through the AUR, as `epitls-pi-bin`
- with cargo `cargo install epitls-pi`
## TODO
- [ ] add support and switch on run/test for strict mode.
- [ ] add `--` syntax to run subcommand for parameter piping.
- [ ] prevent double includes.

View file

@ -89,6 +89,8 @@ fn compilation_args() -> Vec<String> {
"-Wall".to_string(),
"-Wextra".to_string(),
"-std=c99".to_string(),
"-g".to_string(),
"-fsanitize=address".to_string(),
// "-pedantic".to_string(),
];
if Config::get_local_or_default().strict_mode() {

View file

@ -93,7 +93,8 @@ impl RunTask {
}
pub fn run(self) -> Result<(), ExitStatus> {
let mut command = Command::new(self.file);
let mut command = Command::new("sh");
command.args(["-c", self.file.to_str().unwrap()]);
if self.verbose {
log_command_run(&command);
log_separator_top();