LGTM, thanks.

On Mon, Oct 7, 2013 at 4:37 PM, Jose A. Lopes <[email protected]> wrote:

> Update reference to constant 'confdMagicFourcc' to fetch its value
> from 'Ganeti.Constants' instead of the re-export from module
> 'Ganeti.Confd.Types'.
>
> Signed-off-by: Jose A. Lopes <[email protected]>
> ---
>  src/Ganeti/Confd/Server.hs | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/Ganeti/Confd/Server.hs b/src/Ganeti/Confd/Server.hs
> index 25cbb17..99f66c7 100644
> --- a/src/Ganeti/Confd/Server.hs
> +++ b/src/Ganeti/Confd/Server.hs
> @@ -246,7 +246,7 @@ respondInner cfg hmac rq =
>        innermsg = serializeResponse (cfg >>= flip buildResponse rq)
>        innerserialised = J.encodeStrict innermsg
>        outermsg = signMessage hmac rsalt innerserialised
> -      outerserialised = confdMagicFourcc ++ J.encodeStrict outermsg
> +      outerserialised = C.confdMagicFourcc ++ J.encodeStrict outermsg
>    in outerserialised
>
>  -- | Main listener loop.
> @@ -255,7 +255,7 @@ listener :: S.Socket -> HashKey
>           -> IO ()
>  listener s hmac resp = do
>    (msg, _, peer) <- S.recvFrom s 4096
> -  if confdMagicFourcc `isPrefixOf` msg
> +  if C.confdMagicFourcc `isPrefixOf` msg
>      then forkIO (resp s hmac (drop 4 msg) peer) >> return ()
>      else logDebug "Invalid magic code!" >> return ()
>    return ()
> --
> 1.8.4
>
>


-- 
Thomas Thrainer | Software Engineer | [email protected] |

Google Germany GmbH
Dienerstr. 12
80331 München

Registergericht und -nummer: Hamburg, HRB 86891
Sitz der Gesellschaft: Hamburg
Geschäftsführer: Graham Law, Christine Elizabeth Flores

Reply via email to