MCPcopy Create free account
hub / github.com/PerroEngine/Perro / write_http_response

Function write_http_response

perro_source/devtools/perro_cli/src/project.rs:1283–1297  ·  view source on GitHub ↗
(
    stream: &mut TcpStream,
    status: &str,
    content_type: &str,
    body: &[u8],
)

Source from the content-addressed store, hash-verified

1281 cmd.arg("--release");
1282 }
1283 let status = cmd.status().map_err(|err| {
1284 format!(
1285 "failed to launch cargo apk run from {}: {err}",
1286 project_crate.display()
1287 )
1288 })?;
1289 if !status.success() {
1290 return Err(format!(
1291 "cargo apk run failed with exit code {:?}. ensure an emulator or android device is available.",
1292 status.code()
1293 ));
1294 }
1295 log_done("Android App Finished");
1296 Ok(())
1297}
1298
1299fn find_android_sdk_root() -> Option<PathBuf> {
1300 let mut candidates = Vec::<PathBuf>::new();

Callers 1

handle_http_connectionFunction · 0.85

Calls 2

write_allMethod · 0.80
as_bytesMethod · 0.45

Tested by

no test coverage detected