ctorrent stat collector
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

34 lines
653B

  1. #ifndef _TORRENTFILE_H_
  2. #define _TORRENTFILE_H_
  3. #include "list.h"
  4. #include "spawn.h"
  5. extern struct list_head torrent_list;
  6. struct torrent_file {
  7. /* list of torrent files */
  8. struct list_head list;
  9. /* list of clients in this cloud */
  10. struct list_head client_list;
  11. /* name of torrentfile */
  12. char *name;
  13. /* local seeder process */
  14. struct child_process *child;
  15. /* destroy torrent after child-exit */
  16. int destroy;
  17. };
  18. struct torrent_file * find_create_torrent(const char *fullpath);
  19. int destroy_torrent(struct torrent_file *torrent);
  20. int seed_torrent(struct torrent_file *torrent);
  21. int torrentfile_init(void);
  22. #endif /* _TORRENTFILE_H_ */