Skip to content
Snippets Groups Projects
  • Dovid Bender's avatar
    bc58e84f
    func_curl.c: Allow user to set what return codes constitute a failure. · bc58e84f
    Dovid Bender authored
    Currently any response from res_curl where we get an answer from the
    web server, regardless of what the response is (404, 403 etc.) Asterisk
    currently treats it as a success. This patch allows you to set which
    codes should be considered as a failure by Asterisk. If say we set
    failurecodes=404,403 then when using curl in realtime if a server gives
    a 404 error Asterisk will try to failover to the next option set in
    extconfig.conf
    
    ASTERISK-28825
    
    Reported by: Dovid Bender
    Code by: Gobinda Paul
    
    Change-Id: I94443e508343e0a3e535e51ea6e0562767639987
    bc58e84f
    History
    func_curl.c: Allow user to set what return codes constitute a failure.
    Dovid Bender authored
    Currently any response from res_curl where we get an answer from the
    web server, regardless of what the response is (404, 403 etc.) Asterisk
    currently treats it as a success. This patch allows you to set which
    codes should be considered as a failure by Asterisk. If say we set
    failurecodes=404,403 then when using curl in realtime if a server gives
    a 404 error Asterisk will try to failover to the next option set in
    extconfig.conf
    
    ASTERISK-28825
    
    Reported by: Dovid Bender
    Code by: Gobinda Paul
    
    Change-Id: I94443e508343e0a3e535e51ea6e0562767639987