mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-03-31 17:55:36 +00:00
aquatic http protocol: AnnounceRequest.write: write actual event
This commit is contained in:
parent
953154824e
commit
7d4b1ab610
1 changed files with 6 additions and 1 deletions
|
|
@ -35,7 +35,12 @@ impl AnnounceRequest {
|
||||||
output.write(b"&left=")?;
|
output.write(b"&left=")?;
|
||||||
output.write(itoa::Buffer::new().format(self.bytes_left).as_bytes())?;
|
output.write(itoa::Buffer::new().format(self.bytes_left).as_bytes())?;
|
||||||
|
|
||||||
output.write(b"&event=started")?; // FIXME
|
match self.event {
|
||||||
|
AnnounceEvent::Started => output.write(b"&event=started")?,
|
||||||
|
AnnounceEvent::Stopped => output.write(b"&event=stopped")?,
|
||||||
|
AnnounceEvent::Completed => output.write(b"&event=completed")?,
|
||||||
|
AnnounceEvent::Empty => 0,
|
||||||
|
};
|
||||||
|
|
||||||
output.write(b"&compact=")?;
|
output.write(b"&compact=")?;
|
||||||
output.write(itoa::Buffer::new().format(self.compact as u8).as_bytes())?;
|
output.write(itoa::Buffer::new().format(self.compact as u8).as_bytes())?;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue