odoo/odoo — pull request #2303 by YingLiu4203 (2014-09-10 03:13:21+00:00)
Title: fix logging to file in Windows

**In Windows, Odoo fails to write log messages to a configured logfile**

Impacted versions:
* 7.0 and above

Steps to reproduce:

1. Install Odoo in Windows
2. set `logfile = c:\odoo.log` in openerp-server.conf file
3. Run Odoo in Windows, all log messages are still written to console.

Expected behavior:

1. Log messages should be written to the configure log file.

The reason and the fix:
The reason is that a code error in openrp/netsvc.py.
The 'FileHandler` class is defined
in `logging` module, not in `logging.handlers` module.

The fix is to change the line from
>handler = logging.handlers.FileHandler(logf)

to

> handler = logging.FileHandler(logf)