| Index: third_party/WebKit/Tools/Scripts/webkit-patch
|
| diff --git a/third_party/WebKit/Tools/Scripts/webkit-patch b/third_party/WebKit/Tools/Scripts/webkit-patch
|
| index 4a0c37edd1dc25e9ca219a920c6da1dc5e14e927..43080e11021ca4d7231a058c8abf6c82823615c5 100755
|
| --- a/third_party/WebKit/Tools/Scripts/webkit-patch
|
| +++ b/third_party/WebKit/Tools/Scripts/webkit-patch
|
| @@ -29,11 +29,8 @@
|
| # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
| # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
| # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| -#
|
| -# A tool for automating dealing with bugzilla, posting patches, committing patches, etc.
|
|
|
| import logging
|
| -import os
|
| import signal
|
| import sys
|
| import codecs
|
| @@ -53,14 +50,14 @@ from webkitpy.tool.webkit_patch import WebKitPatch
|
|
|
| class ForgivingUTF8Writer(codecs.lookup('utf-8')[-1]):
|
|
|
| - def write(self, object):
|
| - if isinstance(object, str):
|
| + def write(self, obj):
|
| + if isinstance(obj, str):
|
| # Assume raw strings are utf-8 encoded. If this line
|
| # fails with an UnicodeDecodeError, our assumption was
|
| # wrong, and the stacktrace should show you where we
|
| # write non-Unicode/UTF-8 data (which we shouldn't).
|
| - object = object.decode('utf-8')
|
| - return codecs.StreamWriter.write(self, object)
|
| + obj = obj.decode('utf-8')
|
| + return codecs.StreamWriter.write(self, obj)
|
|
|
| # By default, sys.stdout assumes ascii encoding. Since our messages can
|
| # contain unicode strings (as with some peoples' names) we need to apply
|
| @@ -80,7 +77,7 @@ def main():
|
| else:
|
| logging_level = logging.INFO
|
| configure_logging(logging_level=logging_level)
|
| - WebKitPatch(os.path.abspath(__file__)).main()
|
| + WebKitPatch().main()
|
|
|
|
|
| if __name__ == "__main__":
|
|
|