add warning to spawn function

This commit is contained in:
mykola2312 2024-02-24 14:55:37 +02:00
parent 2dba73a464
commit a1515522a4

View file

@ -34,6 +34,8 @@ impl fmt::Display for SpawnError {
} }
} }
/* !!! The argument list could be exploited in a way to inject malicious arguments !!!
!!! and alter the way program executes and/or gain access to system !!! */
pub async fn spawn<I, S>(program: &str, args: I) -> Result<Output, SpawnError> pub async fn spawn<I, S>(program: &str, args: I) -> Result<Output, SpawnError>
where where
I: IntoIterator<Item = S>, I: IntoIterator<Item = S>,