fork(1) download
  1. #include <vector>
  2. #include <iostream>
  3.  
  4. typedef void* SESSION; // Or whatever it is
  5. typedef void* DELIVERY_MODE; // You didn't say what these are
  6. typedef void* (*Func) (SESSION, DELIVERY_MODE, DELIVERY_MODE);
  7. typedef std::vector<Func> FuncVector;
  8.  
  9. FuncVector f_callbackVector;
  10. FuncVector::iterator f_callbackVectorIterator = f_callbackVector.begin();
  11.  
  12. void* handleDeliveryModeChange
  13. (
  14. SESSION s,
  15. const DELIVERY_MODE d1,
  16. const DELIVERY_MODE d2
  17. )
  18. {
  19. if ((*f_callbackVectorIterator) == &handleDeliveryModeChange)
  20. {
  21. std::cout << "\n\n\n\nWOW\n\n\n\n";
  22. }
  23. }
  24.  
  25. int main()
  26. {
  27.  
  28. f_callbackVector.push_back(handleDeliveryModeChange);
  29. }
Success #stdin #stdout 0s 2980KB
stdin
Standard input is empty
stdout
Standard output is empty