Changeset 247 in flair-src for trunk/lib


Ignore:
Timestamp:
May 28, 2018, 6:23:35 PM (7 years ago)
Author:
Sanahuja Guillaume
Message:

improve gcs disconnections

Location:
trunk/lib
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/FlairCore/src/ui_com.cpp

    r243 r247  
    105105  if (UDT::setsockopt(socket_fd, 0, UDT_RCVTIMEO, &timeout, sizeof(int)) != 0)
    106106    Err("UDT::setsockopt error (UDT_RCVTIMEO)\n");
    107 
     107    /*
     108  timeout=-1;
     109  if (UDT::setsockopt(socket_fd, 0, UDT_SNDTIMEO, &timeout, sizeof(int)) != 0)
     110    Err("UDT::setsockopt error (UDT_SNDTIMEO)\n");
     111*/
    108112  bool blocking = true;
    109113  if (UDT::setsockopt(socket_fd, 0, UDT_SNDSYN, &blocking, sizeof(bool)) != 0)
     
    138142
    139143  Join();
    140 
     144 
     145  char buf=CLOSING_CONNECTION;
     146  Send(&buf,1);
     147 
    141148  if (send_buffer != NULL)
    142149    free(send_buffer);
     
    196203  nb_write = UDT::sendmsg(socket_fd, tosend, size, -1, true);
    197204#endif // COMPRESS_FRAMES
    198   // Printf("write %i %i\n",nb_write,size);
     205   //Printf("write %i %i\n",nb_write,size);
    199206  if (nb_write < 0) {
    200207    Err("UDT::sendmsg error (%s)\n", UDT::getlasterror().getErrorMessage());
  • trunk/lib/FlairCore/src/unexported/communication.h

    r234 r247  
    1212#define DATAS_LITTLE_ENDIAN 0x02
    1313#define DATAS_BIG_ENDIAN 0x03
     14#define CLOSING_CONNECTION 0x04
    1415
     16//messages file socket
    1517#define START_SENDING_FILES 0x10
    1618#define FILE_INFO_LITTLE_ENDIAN 0x11
  • trunk/lib/FlairFilter/src/Pid.cpp

    r214 r247  
    4747}
    4848
     49float Pid::GetIntegral(void) const { return pimpl_->i; }
     50
    4951void Pid::UpdateFrom(const io_data *data) {
    5052  pimpl_->UpdateFrom(data);
  • trunk/lib/FlairFilter/src/Pid.h

    r15 r247  
    5858  */
    5959  void Reset(void);
     60 
     61   /*!
     62  * \brief Get intergral part
     63  *
     64  * \return current integral part
     65  */
     66  float GetIntegral(void) const;
     67
    6068
    6169  /*!
Note: See TracChangeset for help on using the changeset viewer.