Saggi Mizrahi has posted comments on this change. Change subject: infra: Add filecontrol module ......................................................................
Patch Set 3: Code-Review-1 (2 comments) http://gerrit.ovirt.org/#/c/35918/3/lib/vdsm/infra/filecontrol/__init__.py File lib/vdsm/infra/filecontrol/__init__.py: Line 30: old_flags = fcntl.fcntl(fd, fcntl.F_GETFD) Line 31: return fcntl.fcntl(fd, fcntl.F_SETFD, old_flags | flags) Line 32: Line 33: Line 34: def set_non_blocking(fd): There is no way to unset Also you don't support passing a file object. You could change it to: def set_non_blocking(f, value=True): fd = getattr(f, "fileno", lambda : f)() Line 35: """Set O_NONBLOCK flag on file descriptor""" Line 36: return _add_file_flags(fd, os.O_NONBLOCK) Line 37: Line 38: Line 34: def set_non_blocking(fd): Line 35: """Set O_NONBLOCK flag on file descriptor""" Line 36: return _add_file_flags(fd, os.O_NONBLOCK) Line 37: Line 38: same as above Line 39: def set_close_on_exec(fd): Line 40: """Set O_CLOEXEC flag on file descriptor""" -- To view, visit http://gerrit.ovirt.org/35918 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: comment Gerrit-Change-Id: I4f455711d81e84db600647a2d5d80a5e7cadd5e2 Gerrit-PatchSet: 3 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Dima Kuznetsov <dkuzn...@redhat.com> Gerrit-Reviewer: Dan Kenigsberg <dan...@redhat.com> Gerrit-Reviewer: Saggi Mizrahi <smizr...@redhat.com> Gerrit-Reviewer: Yaniv Bronhaim <ybron...@redhat.com> Gerrit-Reviewer: Yeela Kaplan <ykap...@redhat.com> Gerrit-Reviewer: automat...@ovirt.org Gerrit-Reviewer: mooli tayer <mta...@redhat.com> Gerrit-Reviewer: oVirt Jenkins CI Server Gerrit-HasComments: Yes _______________________________________________ vdsm-patches mailing list vdsm-patches@lists.fedorahosted.org https://lists.fedorahosted.org/mailman/listinfo/vdsm-patches