llfuse-1.3.3/0000775000175000017500000000000013257663654014515 5ustar nikrationikratio00000000000000llfuse-1.3.3/util/0000775000175000017500000000000013257663654015472 5ustar nikrationikratio00000000000000llfuse-1.3.3/util/sphinx_cython.py0000644000175000017500000000212612557232665020734 0ustar nikrationikratio00000000000000# -*- coding: utf-8 -*- ''' sphinx_cython.py This module removes C style type declarations from function and method docstrings. It also works around http://trac.cython.org/cython_trac/ticket/812 Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import import re TYPE_RE = re.compile(r'(int|char|unicode|str|bytes)(?:\s+\*?\s*|\s*\*?\s+)([a-zA-Z_].*)') def setup(app): app.connect('autodoc-process-signature', process_signature) def process_signature(app, what, name, obj, options, signature, return_annotation): # Some unused arguments #pylint: disable=W0613 if signature is None: return (signature, return_annotation) new_params = list() for param in (x.strip() for x in signature[1:-1].split(',')): hit = TYPE_RE.match(param) if hit: new_params.append(hit.group(2)) else: new_params.append(param) return ('(%s)' % ', '.join(new_params), return_annotation) llfuse-1.3.3/README.rst0000664000175000017500000000453313202375625016175 0ustar nikrationikratio00000000000000.. NOTE: We cannot use sophisticated ReST syntax (like e.g. :file:`foo`) here because this isn't rendered correctly by PyPi and/or BitBucket. The Python-LLFUSE Module ======================== .. start-intro Python-LLFUSE is a set of Python bindings for the low level FUSE_ API. It requires at least FUSE 2.8.0 and supports both Python 2.x and 3.x. Like FUSE itself, Python-LLFUSE is developed for Linux systems. However, we try to maintain compatibility with OS-X, FreeBSD and NetBSD as well (but due to lack of pre-release testers we can't guarantee that every Python-LLFUSE release will run on these platforms - please report any bugs and we will try to fix them). Python-LLFUSE releases can be downloaded from PyPi_. The documentation can be `read online`__ and is also included in the ``doc/html`` directory of the Python-LLFUSE tarball. Getting Help ------------ Please report any bugs on the `issue tracker`_. For discussion and questions, please use the general `FUSE mailing list`_. A searchable `mailing list archive`_ is kindly provided by Gmane_. Development Status ------------------ The Python-LLFUSE API is not yet stable and may change from one release to the other. Starting with version 0.42, Python-LLFUSE uses semantic versioning. This means changes in the API will be reflected in an increase of the major version number, i.e. the next backwards-incompatible version will be 1.0. Projects designed for e.g. version 0.42.1 of Python-LLFUSE are thus recommended to declare a dependency on ``llfuse >= 0.42.1, < 1.0``. Contributing ------------ The Python-LLFUSE source code is available both on GitHub_ and BitBucket_. Professional Support -------------------- Professional support is offered via `Rath Consulting`_. .. __: http://www.rath.org/llfuse-docs/ .. _FUSE: http://github.com/libfuse/libfuse .. _FUSE mailing list: https://lists.sourceforge.net/lists/listinfo/fuse-devel .. _issue tracker: https://bitbucket.org/nikratio/python-llfuse/issues .. _mailing list archive: http://dir.gmane.org/gmane.comp.file-systems.fuse.devel .. _Gmane: http://www.gmane.org/ .. _PyPi: https://pypi.python.org/pypi/llfuse/ .. _BitBucket: https://bitbucket.org/nikratio/python-llfuse/ .. _GitHub: https://github.com/python-llfuse/python-llfuse .. _`Rath Consulting`: http://www.rath-consulting.biz/ llfuse-1.3.3/LICENSE0000644000175000017500000006255012505143303015503 0ustar nikrationikratio00000000000000This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. For reference, the full text of the GNU Lesser General Public License Version 2 is included below: GNU LIBRARY GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1991 Free Software Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. [This is the first released version of the library GPL. It is numbered 2 because it goes with version 2 of the ordinary GPL.] Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public Licenses are intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This license, the Library General Public License, applies to some specially designated Free Software Foundation software, and to any other libraries whose authors decide to use it. You can use it for your libraries, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the library, or if you modify it. For example, if you distribute copies of the library, whether gratis or for a fee, you must give the recipients all the rights that we gave you. You must make sure that they, too, receive or can get the source code. If you link a program with the library, you must provide complete object files to the recipients so that they can relink them with the library, after making changes to the library and recompiling it. And you must show them these terms so they know their rights. Our method of protecting your rights has two steps: (1) copyright the library, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the library. Also, for each distributor's protection, we want to make certain that everyone understands that there is no warranty for this free library. If the library is modified by someone else and passed on, we want its recipients to know that what they have is not the original version, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that companies distributing free software will individually obtain patent licenses, thus in effect transforming the program into proprietary software. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. Most GNU software, including some libraries, is covered by the ordinary GNU General Public License, which was designed for utility programs. This license, the GNU Library General Public License, applies to certain designated libraries. This license is quite different from the ordinary one; be sure to read it in full, and don't assume that anything in it is the same as in the ordinary license. The reason we have a separate public license for some libraries is that they blur the distinction we usually make between modifying or adding to a program and simply using it. Linking a program with a library, without changing the library, is in some sense simply using the library, and is analogous to running a utility program or application program. However, in a textual and legal sense, the linked executable is a combined work, a derivative of the original library, and the ordinary General Public License treats it as such. Because of this blurred distinction, using the ordinary General Public License for libraries did not effectively promote software sharing, because most developers did not use the libraries. We concluded that weaker conditions might promote sharing better. However, unrestricted linking of non-free programs would deprive the users of those programs of all benefit from the free status of the libraries themselves. This Library General Public License is intended to permit developers of non-free programs to use free libraries, while preserving your freedom as a user of such programs to change the free libraries that are incorporated in them. (We have not seen how to achieve this as regards changes in header files, but we have achieved it as regards changes in the actual functions of the Library.) The hope is that this will lead to faster development of free libraries. The precise terms and conditions for copying, distribution and modification follow. Pay close attention to the difference between a "work based on the library" and a "work that uses the library". The former contains code derived from the library, while the latter only works together with the library. Note that it is possible for a library to be covered by the ordinary General Public License rather than by this special one. GNU LIBRARY GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License Agreement applies to any software library which contains a notice placed by the copyright holder or other authorized party saying it may be distributed under the terms of this Library General Public License (also called "this License"). Each licensee is addressed as "you". A "library" means a collection of software functions and/or data prepared so as to be conveniently linked with application programs (which use some of those functions and data) to form executables. The "Library", below, refers to any such software library or work which has been distributed under these terms. A "work based on the Library" means either the Library or any derivative work under copyright law: that is to say, a work containing the Library or a portion of it, either verbatim or with modifications and/or translated straightforwardly into another language. (Hereinafter, translation is included without limitation in the term "modification".) "Source code" for a work means the preferred form of the work for making modifications to it. For a library, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the library. Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running a program using the Library is not restricted, and output from such a program is covered only if its contents constitute a work based on the Library (independent of the use of the Library in a tool for writing it). Whether that is true depends on what the Library does and what the program that uses the Library does. 1. You may copy and distribute verbatim copies of the Library's complete source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and distribute a copy of this License along with the Library. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Library or any portion of it, thus forming a work based on the Library, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) The modified work must itself be a software library. b) You must cause the files modified to carry prominent notices stating that you changed the files and the date of any change. c) You must cause the whole of the work to be licensed at no charge to all third parties under the terms of this License. d) If a facility in the modified Library refers to a function or a table of data to be supplied by an application program that uses the facility, other than as an argument passed when the facility is invoked, then you must make a good faith effort to ensure that, in the event an application does not supply such function or table, the facility still operates, and performs whatever part of its purpose remains meaningful. (For example, a function in a library to compute square roots has a purpose that is entirely well-defined independent of the application. Therefore, Subsection 2d requires that any application-supplied function or table used by this function must be optional: if the application does not supply it, the square root function must still compute square roots.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Library, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Library, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Library. In addition, mere aggregation of another work not based on the Library with the Library (or with a work based on the Library) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may opt to apply the terms of the ordinary GNU General Public License instead of this License to a given copy of the Library. To do this, you must alter all the notices that refer to this License, so that they refer to the ordinary GNU General Public License, version 2, instead of to this License. (If a newer version than version 2 of the ordinary GNU General Public License has appeared, then you can specify that version instead if you wish.) Do not make any other change in these notices. Once this change is made in a given copy, it is irreversible for that copy, so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy. This option is useful when you wish to copy part of the code of the Library into a program that is not a library. 4. You may copy and distribute the Library (or a portion or derivative of it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange. If distribution of object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code, even though third parties are not compelled to copy the source along with the object code. 5. A program that contains no derivative of any portion of the Library, but is designed to work with the Library by being compiled or linked with it, is called a "work that uses the Library". Such a work, in isolation, is not a derivative work of the Library, and therefore falls outside the scope of this License. However, linking a "work that uses the Library" with the Library creates an executable that is a derivative of the Library (because it contains portions of the Library), rather than a "work that uses the library". The executable is therefore covered by this License. Section 6 states terms for distribution of such executables. When a "work that uses the Library" uses material from a header file that is part of the Library, the object code for the work may be a derivative work of the Library even though the source code is not. Whether this is true is especially significant if the work can be linked without the Library, or if the work is itself a library. The threshold for this to be true is not precisely defined by law. If such an object file uses only numerical parameters, data structure layouts and accessors, and small macros and small inline functions (ten lines or less in length), then the use of the object file is unrestricted, regardless of whether it is legally a derivative work. (Executables containing this object code plus portions of the Library will still fall under Section 6.) Otherwise, if the work is a derivative of the Library, you may distribute the object code for the work under the terms of Section 6. Any executables containing that work also fall under Section 6, whether or not they are linked directly with the Library itself. 6. As an exception to the Sections above, you may also compile or link a "work that uses the Library" with the Library to produce a work containing portions of the Library, and distribute that work under terms of your choice, provided that the terms permit modification of the work for the customer's own use and reverse engineering for debugging such modifications. You must give prominent notice with each copy of the work that the Library is used in it and that the Library and its use are covered by this License. You must supply a copy of this License. If the work during execution displays copyright notices, you must include the copyright notice for the Library among them, as well as a reference directing the user to the copy of this License. Also, you must do one of these things: a) Accompany the work with the complete corresponding machine-readable source code for the Library including whatever changes were used in the work (which must be distributed under Sections 1 and 2 above); and, if the work is an executable linked with the Library, with the complete machine-readable "work that uses the Library", as object code and/or source code, so that the user can modify the Library and then relink to produce a modified executable containing the modified Library. (It is understood that the user who changes the contents of definitions files in the Library will not necessarily be able to recompile the application to use the modified definitions.) b) Accompany the work with a written offer, valid for at least three years, to give the same user the materials specified in Subsection 6a, above, for a charge no more than the cost of performing this distribution. c) If distribution of the work is made by offering access to copy from a designated place, offer equivalent access to copy the above specified materials from the same place. d) Verify that the user has already received a copy of these materials or that you have already sent this user a copy. For an executable, the required form of the "work that uses the Library" must include any data and utility programs needed for reproducing the executable from it. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. It may happen that this requirement contradicts the license restrictions of other proprietary libraries that do not normally accompany the operating system. Such a contradiction means you cannot use both them and the Library together in an executable that you distribute. 7. You may place library facilities that are a work based on the Library side-by-side in a single library together with other library facilities not covered by this License, and distribute such a combined library, provided that the separate distribution of the work based on the Library and of the other library facilities is otherwise permitted, and provided that you do these two things: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities. This must be distributed under the terms of the Sections above. b) Give prominent notice with the combined library of the fact that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 8. You may not copy, modify, sublicense, link with, or distribute the Library except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense, link with, or distribute the Library is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 9. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Library or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Library (or any work based on the Library), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Library or works based on it. 10. Each time you redistribute the Library (or any work based on the Library), the recipient automatically receives a license from the original licensor to copy, distribute, link with or modify the Library subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 11. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Library at all. For example, if a patent license would not permit royalty-free redistribution of the Library by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Library. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply, and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 12. If the distribution and/or use of the Library is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Library under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 13. The Free Software Foundation may publish revised and/or new versions of the Library General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Library specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Library does not specify a license version number, you may choose any version ever published by the Free Software Foundation. 14. If you wish to incorporate parts of the Library into other free programs whose distribution conditions are incompatible with these, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Libraries If you develop a new library, and you want it to be of the greatest possible use to the public, we recommend making it free software that everyone can redistribute and change. You can do so by permitting redistribution under these terms (or, alternatively, under the terms of the ordinary General Public License). To apply these terms, attach the following notices to the library. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the library, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the library `Frob' (a library for tweaking knobs) written by James Random Hacker. , 1 April 1990 Ty Coon, President of Vice That's all there is to it! llfuse-1.3.3/PKG-INFO0000664000175000017500000000733213257663654015617 0ustar nikrationikratio00000000000000Metadata-Version: 1.1 Name: llfuse Version: 1.3.3 Summary: Python bindings for the low-level FUSE API Home-page: https://bitbucket.org/nikratio/python-llfuse/ Author: Nikolaus Rath Author-email: Nikolaus@rath.org License: LGPL Download-URL: https://bitbucket.org/nikratio/python-llfuse/downloads Description: .. NOTE: We cannot use sophisticated ReST syntax (like e.g. :file:`foo`) here because this isn't rendered correctly by PyPi and/or BitBucket. The Python-LLFUSE Module ======================== .. start-intro Python-LLFUSE is a set of Python bindings for the low level FUSE_ API. It requires at least FUSE 2.8.0 and supports both Python 2.x and 3.x. Like FUSE itself, Python-LLFUSE is developed for Linux systems. However, we try to maintain compatibility with OS-X, FreeBSD and NetBSD as well (but due to lack of pre-release testers we can't guarantee that every Python-LLFUSE release will run on these platforms - please report any bugs and we will try to fix them). Python-LLFUSE releases can be downloaded from PyPi_. The documentation can be `read online`__ and is also included in the ``doc/html`` directory of the Python-LLFUSE tarball. Getting Help ------------ Please report any bugs on the `issue tracker`_. For discussion and questions, please use the general `FUSE mailing list`_. A searchable `mailing list archive`_ is kindly provided by Gmane_. Development Status ------------------ The Python-LLFUSE API is not yet stable and may change from one release to the other. Starting with version 0.42, Python-LLFUSE uses semantic versioning. This means changes in the API will be reflected in an increase of the major version number, i.e. the next backwards-incompatible version will be 1.0. Projects designed for e.g. version 0.42.1 of Python-LLFUSE are thus recommended to declare a dependency on ``llfuse >= 0.42.1, < 1.0``. Contributing ------------ The Python-LLFUSE source code is available both on GitHub_ and BitBucket_. Professional Support -------------------- Professional support is offered via `Rath Consulting`_. .. __: http://www.rath.org/llfuse-docs/ .. _FUSE: http://github.com/libfuse/libfuse .. _FUSE mailing list: https://lists.sourceforge.net/lists/listinfo/fuse-devel .. _issue tracker: https://bitbucket.org/nikratio/python-llfuse/issues .. _mailing list archive: http://dir.gmane.org/gmane.comp.file-systems.fuse.devel .. _Gmane: http://www.gmane.org/ .. _PyPi: https://pypi.python.org/pypi/llfuse/ .. _BitBucket: https://bitbucket.org/nikratio/python-llfuse/ .. _GitHub: https://github.com/python-llfuse/python-llfuse .. _`Rath Consulting`: http://www.rath-consulting.biz/ Keywords: FUSE,python Platform: Linux Platform: FreeBSD Platform: OS X Classifier: Development Status :: 4 - Beta Classifier: Intended Audience :: Developers Classifier: Programming Language :: Python Classifier: Topic :: Software Development :: Libraries :: Python Modules Classifier: Topic :: System :: Filesystems Classifier: License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL) Classifier: Operating System :: POSIX :: Linux Classifier: Operating System :: MacOS :: MacOS X Classifier: Operating System :: POSIX :: BSD :: FreeBSD Provides: llfuse llfuse-1.3.3/rst/0000775000175000017500000000000013257663654015325 5ustar nikrationikratio00000000000000llfuse-1.3.3/rst/_templates/0000775000175000017500000000000013257663654017462 5ustar nikrationikratio00000000000000llfuse-1.3.3/rst/_templates/localtoc.html0000644000175000017500000000013512343216623022126 0ustar nikrationikratio00000000000000

{{ _('Table Of Contents') }}

{{ toctree() }} llfuse-1.3.3/rst/_static/0000775000175000017500000000000013257663654016753 5ustar nikrationikratio00000000000000llfuse-1.3.3/rst/_static/.placeholder0000644000175000017500000000000012343216623021203 0ustar nikrationikratio00000000000000llfuse-1.3.3/rst/general.rst0000664000175000017500000000623213202301227017446 0ustar nikrationikratio00000000000000===================== General Information ===================== .. currentmodule:: llfuse .. _getting_started: Getting started =============== A file system is implemented by subclassing the `llfuse.Operations` class and implementing the various request handlers. The handlers respond to requests received from the FUSE kernel module and perform functions like looking up the inode given a file name, looking up attributes of an inode, opening a (file) inode for reading or writing or listing the contents of a (directory) inode. An instance of the operations class is passed to `llfuse.init` to mount the file system. To enter the request handling loop, run `llfuse.main`. This function will return when the file system should be unmounted again, which is done by calling `llfuse.close`. All character data (directory entry names, extended attribute names and values, symbolic link targets etc) are passed as `bytes` and must be returned as `bytes`. This applies to both running under Python 2.x and 3.x For easier debugging, it is strongly recommended that applications using Python-LLFUSE also make use of the faulthandler_ module. .. _faulthandler: http://docs.python.org/3/library/faulthandler.html Lookup Counts ============= Most file systems need to keep track which inodes are currently known to the kernel. This is, for example, necessary to correctly implement the *unlink* system call: when unlinking a directory entry whose associated inode is currently opened, the file system must defer removal of the inode (and thus the file contents) until it is no longer in use by any process. FUSE file systems achieve this by using "lookup counts". A lookup count is a number that's associated with an inode. An inode with a lookup count of zero is currently not known to the kernel. This means that if there are no directory entries referring to such an inode it can be safely removed, or (if a file system implements dynamic inode numbers), the inode number can be safely recycled. The lookup count of an inode is increased by one for each call to the `~Operations.lookup`, `~Operations.create`, `~Operations.symlink`, `~Operations.mknod`, `~Operations.link` and `~Operations.mkdir` handlers. The lookup count is decreased by calls to the `~Operations.forget` handler. FUSE and VFS Locking ==================== FUSE and the kernel's VFS layer provide some basic locking that FUSE file systems automatically take advantage of. Specifically: * Calls to `~Operations.rename`, `~Operations.create`, `~Operations.symlink`, `~Operations.mknod`, `~Operations.link` and `~Operations.mkdir` acquire a write-lock on the inode of the directory in which the respective operation takes place (two in case of rename). * Calls to `~Operations.lookup` acquire a read-lock on the inode of the parent directory (meaning that lookups in the same directory may run concurrently, but never at the same time as e.g. a rename or mkdir operation). * Unless writeback caching is enabled (which Python-LLFUSE does not yet allow), calls to `~Operations.write` for the same inode are automatically serialized (i.e., there are never concurrent calls for the same inode even when multithreading is enabled). llfuse-1.3.3/rst/example.rst0000664000175000017500000000146012653313332017473 0ustar nikrationikratio00000000000000.. _example file system: ====================== Example File Systems ====================== Python-LLFUSE comes with several example file systems in the :file:`examples` directory of the release tarball. For completeness, these examples are also included here. Single-file, Read-only File System ================================== (shipped as :file:`examples/lltest.py`) .. literalinclude:: ../examples/lltest.py :linenos: :language: python In-memory File System ===================== (shipped as :file:`examples/tmpfs.py`) .. literalinclude:: ../examples/tmpfs.py :linenos: :language: python Passthrough / Overlay File System ================================= (shipped as :file:`examples/passthroughfs.py`) .. literalinclude:: ../examples/passthroughfs.py :linenos: :language: python llfuse-1.3.3/rst/util.rst0000664000175000017500000000057513202301227017012 0ustar nikrationikratio00000000000000==================== Utility Functions ==================== The following functions do not necessarily translate to calls to the FUSE library. They are provided because they're potentially useful when implementing file systems in Python. .. currentmodule:: llfuse .. autofunction:: setxattr .. autofunction:: getxattr .. autofunction:: listdir .. autofunction:: get_sup_groups llfuse-1.3.3/rst/lock.rst0000644000175000017500000000400012557232665016773 0ustar nikrationikratio00000000000000================= The global lock ================= .. currentmodule:: llfuse Python-LLFUSE uses a global lock to synchronize concurrent requests. Since the GIL already enforces that Python threads do not run concurrently, this does not result in any additional performance penalties. However, the use of an explicit lock allows direct control over which Python thread is running at a given time. Request handlers will always be called with the global lock acquired. However, they may release the global lock for potentially time consuming operations (like network or disk I/O), or to give other threads a chance to run during longer computations. Non-request handling threads may acquire the global lock to ensure that the execution of a particular code block will not be interrupted by any request handlers. Obviously, any method that directly or indirectly releases the global lock must be prepared to be called again while it has released the lock. In addition, it (and all its callers) must not hold any prior locks, since this may lead to deadlocks when re-acquiring the global lock. For this reason it is crucial that every method that directly or indirectly releases the lock is explicitly marked as such. The global lock is controlled with the `lock` and `lock_released` attributes of the `llfuse` module: .. py:attribute:: lock_released Controls the global lock. This object can be used as a context manager for the ``with`` statement to execute a block of code with the global lock released. .. py:attribute:: lock Controls the global lock. This object can be used as a context manager for the ``with`` statement to execute a block of code with the global lock acquired. Note that this object resembles a ``threading.Lock`` instance but is an instance of the `llfuse.Lock` class which is quite different from ``threading.Lock``. The `lock` object has the following methods: .. class:: llfuse.Lock .. automethod:: Lock.acquire() .. automethod:: Lock.release .. automethod:: Lock.yield_ llfuse-1.3.3/rst/operations.rst0000664000175000017500000000030612557224042020223 0ustar nikrationikratio00000000000000================== Request Handlers ================== (You can use the :ref:`genindex` to directly jump to a specific handler). .. currentmodule:: llfuse .. autoclass:: Operations :members: llfuse-1.3.3/rst/conf.py0000664000175000017500000001504012653313463016611 0ustar nikrationikratio00000000000000# -*- coding: utf-8 -*- # # Python-LLFUSE documentation build configuration file, created by # sphinx-quickstart on Sat Oct 16 14:14:40 2010. # # This file is execfile()d with the current directory set to its containing dir. # # Note that not all possible configuration values are present in this # autogenerated file. # # All configuration values have a default; values that are commented out # serve to show the default. # If extensions (or modules to document with autodoc) are in another directory, # add these directories to sys.path here. If the directory is relative to the # documentation root, use os.path.abspath to make it absolute, like shown here. #sys.path.append(os.path.abspath('.')) #pylint: disable-all #@PydevCodeAnalysisIgnore # -- General configuration ----------------------------------------------------- # Add any Sphinx extension module names here, as strings. They can be extensions # coming with Sphinx (named 'sphinx.ext.*') or your custom ones. extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx_cython' ] # Link to Python standard library intersphinx_mapping = {'python': ('http://docs.python.org/3/', None) } # Add any paths that contain templates here, relative to this directory. templates_path = ['_templates'] # The suffix of source filenames. source_suffix = '.rst' autodoc_docstring_signature = True # The encoding of source files. source_encoding = 'utf-8' # The master toctree document. master_doc = 'index' # Warn about unresolved references nitpicky = True # General information about the project. project = u'Python-LLFUSE' copyright = u'2010-2015, Nikolaus Rath' # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. # # The short X.Y version. version = '1.0' # The full version, including alpha/beta/rc tags. release = '1.0' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. #language = None # There are two options for replacing |today|: either, you set today to some # non-false value, then it is used: #today = '' # Else, today_fmt is used as the format for a strftime call. #today_fmt = '%B %d, %Y' # List of documents that shouldn't be included in the build. unused_docs = [ ] # List of directories, relative to source directory, that shouldn't be searched # for source files. exclude_trees = [] # The reST default role (used for this markup: `text`) to use for all documents. default_role = 'py:obj' primary_domain = 'py' # If true, '()' will be appended to :func: etc. cross-reference text. add_function_parentheses = True # If true, the current module name will be prepended to all description # unit titles (such as .. function::). add_module_names = True # If true, sectionauthor and moduleauthor directives will be shown in the # output. They are ignored by default. show_authors = False # The name of the Pygments (syntax highlighting) style to use. pygments_style = 'sphinx' #pygments_style = 'colorful' highlight_language = 'python' # A list of ignored prefixes for module index sorting. #modindex_common_prefix = [] # -- Options for HTML output --------------------------------------------------- # The theme to use for HTML and HTML Help pages. Major themes that come with # Sphinx are currently 'default' and 'sphinxdoc'. html_theme = 'default' # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. #html_theme_options = {} # Add any paths that contain custom themes here, relative to this directory. #html_theme_path = [] # The name for this set of Sphinx documents. If None, it defaults to # " v documentation". #html_title = None # A shorter title for the navigation bar. Default is the same as html_title. #html_short_title = None # The name of an image file (relative to this directory) to place at the top # of the sidebar. #html_logo = None # The name of an image file (within the static path) to use as favicon of the # docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32 # pixels large. #html_favicon = None # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, # so a file named "default.css" will overwrite the builtin "default.css". html_static_path = ['_static'] # If not '', a 'Last updated on:' timestamp is inserted at every page bottom, # using the given strftime format. #html_last_updated_fmt = '%b %d, %Y' # If true, SmartyPants will be used to convert quotes and dashes to # typographically correct entities. #html_use_smartypants = True # Custom sidebar templates, maps document names to template names. #html_sidebars = {} # Additional templates that should be rendered to pages, maps page names to # template names. #html_additional_pages = {} # If false, no module index is generated. html_use_modindex = False # If false, no index is generated. html_use_index = True # If true, the index is split into individual pages for each letter. html_split_index = False # If true, links to the reST sources are added to the pages. html_show_sourcelink = False # If true, an OpenSearch description file will be output, and all pages will # contain a tag referring to it. The value of this option must be the # base URL from which the finished HTML is served. #html_use_opensearch = '' # If nonempty, this is the file name suffix for HTML files (e.g. ".xhtml"). #html_file_suffix = '' # Output file base name for HTML help builder. htmlhelp_basename = 'llfusedoc' # -- Options for LaTeX output -------------------------------------------------- # The paper size ('letter' or 'a4'). #latex_paper_size = 'letter' # The font size ('10pt', '11pt' or '12pt'). #latex_font_size = '10pt' # Grouping the document tree into LaTeX files. List of tuples # (source start file, target name, title, author, documentclass [howto/manual]). latex_documents = [ ('index', 'llfuse.tex', u'Python-LLFUSE Documentation', u'Nikolaus Rath', 'manual'), ] # The name of an image file (relative to this directory) to place at the top of # the title page. #latex_logo = None # For "manual" documents, if this is true, then toplevel headings are parts, # not chapters. #latex_use_parts = False # Additional stuff for the LaTeX preamble. #latex_preamble = '' # Documents to append as an appendix to all manuals. #latex_appendices = [] # If false, no module index is generated. #latex_use_modindex = True llfuse-1.3.3/rst/install.rst0000664000175000017500000000552313240070763017513 0ustar nikrationikratio00000000000000============== Installation ============== .. highlight:: sh Dependencies ============ In order to build and run Python-LLFUSE you need the following software: * Linux, FreeBSD, NetBSD or MacOS X system * Python_ 2.6 or newer (including Python 3.x), installed with development headers * The `setuptools`_ Python module, version 1.0 or newer. * When running under Python 2.x, the `contextlib2`_ Python module from PyPi. * the `pkg-config`_ tool * the `attr`_ library * A C compiler (only for building) To run the unit tests, you will need * The `py.test`_ module, version 3.3.0 or newer When using Linux, you also need: * Kernel 2.6.9 or newer. Starting with kernel 2.6.26 you will get significantly better write performance, so under Linux you should actually use *2.6.26 or newer whenever possible*. * Version 2.9.0 or newer of the FUSE_ library, including development headers (typically distributions provide them in a *libfuse-devel* or *libfuse-dev* package). In case of FreeBSD and NetBSD you will need: * The FUSE4BSD_ kernel module. For OS-X, you need: * the OSXFUSE_ package. Stable releases =============== To install a stable Python-LLFUSE release: 1. Download and unpack the release tarball from https://pypi.python.org/pypi/llfuse/ 2. Run ``python setup.py build_ext --inplace`` to build the C extension 3. Run ``python -m pytest test/`` to run a self-test. If this fails, ask for help on the `FUSE mailing list`_ or report a bug in the `issue tracker `_. 4. To install system-wide for all users, run ``sudo python setup.py install``. To install into :file:`~/.local`, run ``python setup.py install --user``. Development Version =================== If you have checked out the unstable development version from the repository ( Mercurial_ or Git_ ), a bit more effort is required. You need to also have Cython_ (0.24 or newer) and Sphinx_ (1.1 or newer) installed, and the necessary commands are:: python setup.py build_cython python setup.py build_ext --inplace python -m pytest test/ python setup.py build_sphinx python setup.py install .. _Cython: http://www.cython.org/ .. _Sphinx: http://sphinx.pocoo.org/ .. _Python: http://www.python.org/ .. _FUSE mailing list: https://lists.sourceforge.net/lists/listinfo/fuse-devel .. _`py.test`: https://pypi.python.org/pypi/pytest/ .. _FUSE: http://github.com/libfuse/libfuse .. _attr: http://savannah.nongnu.org/projects/attr/ .. _`pkg-config`: http://www.freedesktop.org/wiki/Software/pkg-config .. _FUSE4BSD: http://www.freshports.org/sysutils/fusefs-kmod/ .. _OSXFUSE: http://osxfuse.github.io/ .. _setuptools: https://pypi.python.org/pypi/setuptools .. _contextlib2: https://pypi.python.org/pypi/contextlib2/ .. _Mercurial: https://bitbucket.org/nikratio/python-llfuse .. _Git: https://github.com/python-llfuse/python-llfuse llfuse-1.3.3/rst/about.rst0000664000175000017500000000012012653313463017147 0ustar nikrationikratio00000000000000======= About ======= .. include:: ../README.rst :start-after: start-intro llfuse-1.3.3/rst/data.rst0000664000175000017500000000552413202301227016745 0ustar nikrationikratio00000000000000================= Data Structures ================= .. currentmodule:: llfuse .. py:data:: ENOATTR This errorcode is unfortunately missing in the `errno` module, so it is provided by Python-LLFUSE instead. .. py:data:: ROOT_INODE The inode of the root directory, i.e. the mount point of the file system. .. py:data:: default_options This is a recommended set of options that should be passed to `llfuse.init` to get reasonable behavior and performance. Python-LLFUSE is compatible with any other combination of options as well, but you should only deviate from the defaults with good reason. (The :samp:`fsname=` option is guaranteed never to be included in the default options, so you can always safely add it to the set). .. autoexception:: FUSEError .. autoclass:: RequestContext .. attribute:: pid .. attribute:: uid .. attribute:: gid .. attribute:: umask .. autoclass:: StatvfsData .. attribute:: f_bsize .. attribute:: f_frsize .. attribute:: f_blocks .. attribute:: f_bfree .. attribute:: f_bavail .. attribute:: f_files .. attribute:: f_ffree .. attribute:: f_favail .. attribute:: f_namemax .. autoclass:: EntryAttributes .. autoattribute:: st_ino .. autoattribute:: generation .. autoattribute:: entry_timeout .. autoattribute:: attr_timeout .. autoattribute:: st_mode .. autoattribute:: st_nlink .. autoattribute:: st_uid .. autoattribute:: st_gid .. autoattribute:: st_rdev .. autoattribute:: st_size .. autoattribute:: st_blksize .. autoattribute:: st_blocks .. autoattribute:: st_atime_ns .. autoattribute:: st_ctime_ns .. autoattribute:: st_mtime_ns .. autoclass:: SetattrFields .. attribute:: update_atime If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_atime_ns` field contains an updated value. .. attribute:: update_mtime If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_mtime_ns` field contains an updated value. .. attribute:: update_mode If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_mode` field contains an updated value. .. attribute:: update_uid If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_uid` field contains an updated value. .. attribute:: update_gid If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_gid` field contains an updated value. .. attribute:: update_size If this attribute is true, it signals the `Operations.setattr` method that the `~EntryAttributes.st_size` field contains an updated value. llfuse-1.3.3/rst/index.rst0000664000175000017500000000063112653313505017150 0ustar nikrationikratio00000000000000============================= Python-LLFUSE Documentation ============================= Table of Contents ----------------- .. module:: llfuse .. toctree:: :maxdepth: 1 about.rst install.rst general.rst fuse_api.rst data.rst lock.rst operations.rst util.rst gotchas.rst example.rst changes.rst Indices and tables ------------------ * :ref:`genindex` * :ref:`search` llfuse-1.3.3/rst/changes.rst0000664000175000017500000000003412653313463017451 0ustar nikrationikratio00000000000000.. include:: ../Changes.rst llfuse-1.3.3/rst/gotchas.rst0000664000175000017500000000154412653313505017475 0ustar nikrationikratio00000000000000================ Common Gotchas ================ .. currentmodule:: llfuse This chapter lists some common gotchas that should be avoided. Removing inodes in unlink handler ================================= If your file system is mounted at :file:`mnt`, the following code should complete without errors:: with open('mnt/file_one', 'w+') as fh1: fh1.write('foo') fh1.flush() with open('mnt/file_one', 'a') as fh2: os.unlink('mnt/file_one') assert 'file_one' not in os.listdir('mnt') fh2.write('bar') os.close(os.dup(fh1.fileno())) fh1.seek(0) assert fh1.read() == 'foobar' If you're getting an error, then you probably did a mistake when implementing the `~Operations.unlink` handler and are removing the file contents when you should be deferring removal to the `~Operations.forget` handler. llfuse-1.3.3/rst/fuse_api.rst0000664000175000017500000000050712653313247017641 0ustar nikrationikratio00000000000000==================== FUSE API Functions ==================== .. currentmodule:: llfuse .. autofunction:: init .. autofunction:: main .. autofunction:: close .. autofunction:: invalidate_inode .. autofunction:: invalidate_entry .. autofunction:: notify_store .. autofunction:: get_ino_t_bits .. autofunction:: get_off_t_bits llfuse-1.3.3/setup.cfg0000644000175000017500000000016013257663654016331 0ustar nikrationikratio00000000000000[sdist] formats = bztar [build_sphinx] source-dir = rst build-dir = doc [egg_info] tag_build = tag_date = 0 llfuse-1.3.3/test/0000775000175000017500000000000013257663654015474 5ustar nikrationikratio00000000000000llfuse-1.3.3/test/test_fs.py0000755000175000017500000002041012771372036017502 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' test_fs.py - Unit tests for Python-LLFUSE. Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import import pytest import sys if __name__ == '__main__': sys.exit(pytest.main([__file__] + sys.argv[1:])) import llfuse from llfuse import FUSEError import multiprocessing import os import errno import stat import time import logging import threading from util import fuse_test_marker, wait_for_mount, umount, cleanup, wait_for pytestmark = fuse_test_marker() @pytest.yield_fixture() def testfs(tmpdir): # We can't use forkserver because we have to make sure # that the server inherits the per-test stdout/stderr file # descriptors. if hasattr(multiprocessing, 'get_context'): mp = multiprocessing.get_context('fork') else: # Older versions only support *fork* anyway mp = multiprocessing if threading.active_count() != 1: raise RuntimeError("Multi-threaded test running is not supported") mnt_dir = str(tmpdir) with mp.Manager() as mgr: cross_process = mgr.Namespace() mount_process = mp.Process(target=run_fs, args=(mnt_dir, cross_process)) mount_process.start() try: wait_for_mount(mount_process, mnt_dir) yield (mnt_dir, cross_process) except: cleanup(mnt_dir) raise else: umount(mount_process, mnt_dir) def test_invalidate_entry(testfs): (mnt_dir, fs_state) = testfs path = os.path.join(mnt_dir, 'message') os.stat(path) assert fs_state.lookup_called fs_state.lookup_called = False os.stat(path) assert not fs_state.lookup_called # Unfortunately there's no way to determine when the # kernel has processed the forget() request, so we # wait longer and longer until it works. def check(_wait_time=[0.01]): llfuse.setxattr(mnt_dir, 'command', b'forget_entry') time.sleep(_wait_time[0]) fs_state.lookup_called = False os.stat(path) _wait_time[0] += max(1, _wait_time[0]) return fs_state.lookup_called assert wait_for(check) def test_invalidate_inode(testfs): (mnt_dir, fs_state) = testfs with open(os.path.join(mnt_dir, 'message'), 'r') as fh: assert fh.read() == 'hello world\n' assert fs_state.read_called fs_state.read_called = False fh.seek(0) assert fh.read() == 'hello world\n' assert not fs_state.read_called # Unfortunately there's no way to determine when the # kernel has processed the forget() request, so we # wait longer and longer until it works. def check(_wait_time=[0.01]): llfuse.setxattr(mnt_dir, 'command', b'forget_inode') time.sleep(_wait_time[0]) fs_state.read_called = False fh.seek(0) assert fh.read() == 'hello world\n' _wait_time[0] += max(1, _wait_time[0]) return fs_state.read_called assert wait_for(check) def test_notify_store(testfs): (mnt_dir, fs_state) = testfs with open(os.path.join(mnt_dir, 'message'), 'r') as fh: llfuse.setxattr(mnt_dir, 'command', b'store') fs_state.read_called = False assert fh.read() == 'hello world\n' assert not fs_state.read_called def test_entry_timeout(testfs): (mnt_dir, fs_state) = testfs fs_state.entry_timeout = 1 path = os.path.join(mnt_dir, 'message') os.stat(path) assert fs_state.lookup_called fs_state.lookup_called = False os.stat(path) assert not fs_state.lookup_called time.sleep(fs_state.entry_timeout*1.1) fs_state.lookup_called = False os.stat(path) assert fs_state.lookup_called def test_attr_timeout(testfs): (mnt_dir, fs_state) = testfs fs_state.attr_timeout = 1 with open(os.path.join(mnt_dir, 'message'), 'r') as fh: os.fstat(fh.fileno()) assert fs_state.getattr_called fs_state.getattr_called = False os.fstat(fh.fileno()) assert not fs_state.getattr_called time.sleep(fs_state.attr_timeout*1.1) fs_state.getattr_called = False os.fstat(fh.fileno()) assert fs_state.getattr_called class Fs(llfuse.Operations): def __init__(self, cross_process): super(Fs, self).__init__() self.hello_name = b"message" self.hello_inode = llfuse.ROOT_INODE+1 self.hello_data = b"hello world\n" self.status = cross_process self.lookup_cnt = 0 self.status.getattr_called = False self.status.lookup_called = False self.status.read_called = False self.status.entry_timeout = 2 self.status.attr_timeout = 2 def getattr(self, inode, ctx=None): entry = llfuse.EntryAttributes() if inode == llfuse.ROOT_INODE: entry.st_mode = (stat.S_IFDIR | 0o755) entry.st_size = 0 elif inode == self.hello_inode: entry.st_mode = (stat.S_IFREG | 0o644) entry.st_size = len(self.hello_data) else: raise llfuse.FUSEError(errno.ENOENT) stamp = int(1438467123.985654*1e9) entry.st_atime_ns = stamp entry.st_ctime_ns = stamp entry.st_mtime_ns = stamp entry.st_gid = os.getgid() entry.st_uid = os.getuid() entry.st_ino = inode entry.entry_timeout = self.status.entry_timeout entry.attr_timeout = self.status.attr_timeout self.status.getattr_called = True return entry def forget(self, inode_list): for (inode, cnt) in inode_list: if inode == self.hello_inode: self.lookup_cnt -= 1 assert self.lookup_cnt >= 0 else: assert inode == llfuse.ROOT_INODE def lookup(self, parent_inode, name, ctx=None): if parent_inode != llfuse.ROOT_INODE or name != self.hello_name: raise llfuse.FUSEError(errno.ENOENT) self.lookup_cnt += 1 self.status.lookup_called = True return self.getattr(self.hello_inode) def opendir(self, inode, ctx): if inode != llfuse.ROOT_INODE: raise llfuse.FUSEError(errno.ENOENT) return inode def readdir(self, fh, off): assert fh == llfuse.ROOT_INODE if off == 0: yield (self.hello_name, self.getattr(self.hello_inode), 1) def open(self, inode, flags, ctx): if inode != self.hello_inode: raise llfuse.FUSEError(errno.ENOENT) if flags & os.O_RDWR or flags & os.O_WRONLY: raise llfuse.FUSEError(errno.EPERM) return inode def read(self, fh, off, size): assert fh == self.hello_inode self.status.read_called = True return self.hello_data[off:off+size] def setxattr(self, inode, name, value, ctx): if inode != llfuse.ROOT_INODE or name != b'command': raise FUSEError(errno.ENOTSUP) if value == b'forget_entry': llfuse.invalidate_entry(llfuse.ROOT_INODE, self.hello_name) elif value == b'forget_inode': llfuse.invalidate_inode(self.hello_inode) elif value == b'store': llfuse.notify_store(self.hello_inode, offset=0, data=self.hello_data) else: raise FUSEError(errno.EINVAL) def run_fs(mountpoint, cross_process): # Logging (note that we run in a new process, so we can't # rely on direct log capture and instead print to stdout) root_logger = logging.getLogger() formatter = logging.Formatter('%(asctime)s.%(msecs)03d %(levelname)s ' '%(funcName)s(%(threadName)s): %(message)s', datefmt="%M:%S") handler = logging.StreamHandler(sys.stdout) handler.setLevel(logging.DEBUG) handler.setFormatter(formatter) root_logger.addHandler(handler) root_logger.setLevel(logging.DEBUG) testfs = Fs(cross_process) fuse_options = set(llfuse.default_options) fuse_options.add('fsname=llfuse_testfs') llfuse.init(testfs, mountpoint, fuse_options) try: llfuse.main(workers=1) finally: llfuse.close() llfuse-1.3.3/test/travis-install.sh0000775000175000017500000000010513257655256021002 0ustar nikrationikratio00000000000000#!/bin/sh set -e pip install pytest cython sphinx cython --version llfuse-1.3.3/test/travis-test.sh0000775000175000017500000000021313240070772020275 0ustar nikrationikratio00000000000000#!/bin/bash set -e python setup.py build_cython python setup.py build_ext --inplace python -m pytest test/ python setup.py build_sphinx llfuse-1.3.3/test/pytest_checklogs.py0000664000175000017500000001116113256761712021411 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 ''' pytest_checklogs.py - this file is part of S3QL. Copyright (C) 2008 Nikolaus Rath This work can be distributed under the terms of the GNU GPLv3. py.test plugin to look for suspicious phrases in messages emitted on stdout/stderr or via the logging module. False positives can be registered via a new `reg_output` fixture (for messages to stdout/stderr), and a `assert_logs` function (for logging messages). ''' import pytest import re import functools import sys import logging from contextlib import contextmanager from distutils.version import LooseVersion def pytest_configure(config): # pytest-catchlog was integrated in pytest 3.3.0 if (LooseVersion(pytest.__version__) < "3.3.0" and not config.pluginmanager.hasplugin('pytest_catchlog')): raise ImportError('pytest catchlog plugin not found') # Fail tests if they result in log messages of severity WARNING or more. def check_test_log(caplog): for record in caplog.records: if (record.levelno >= logging.WARNING and not getattr(record, 'checklogs_ignore', False)): raise AssertionError('Logger received warning messages') class CountMessagesHandler(logging.Handler): def __init__(self, level=logging.NOTSET): super().__init__(level) self.count = 0 def emit(self, record): self.count += 1 @contextmanager def assert_logs(pattern, level=logging.WARNING, count=None): '''Assert that suite emits specified log message *pattern* is matched against the *unformatted* log message, i.e. before any arguments are merged. If *count* is not None, raise an exception unless exactly *count* matching messages are caught. Matched log records will also be flagged so that the caplog fixture does not generate exceptions for them (no matter their severity). ''' def filter(record): if (record.levelno == level and re.search(pattern, record.msg)): record.checklogs_ignore = True return True return False handler = CountMessagesHandler() handler.setLevel(level) handler.addFilter(filter) logger = logging.getLogger() logger.addHandler(handler) try: yield finally: logger.removeHandler(handler) if count is not None and handler.count != count: raise AssertionError('Expected to catch %d %r messages, but got only %d' % (count, pattern, handler.count)) def check_test_output(capfd, item): (stdout, stderr) = capfd.readouterr() # Write back what we've read (so that it will still be printed) sys.stdout.write(stdout) sys.stderr.write(stderr) # Strip out false positives try: false_pos = item.checklogs_fp except AttributeError: false_pos = () for (pattern, flags, count) in false_pos: cp = re.compile(pattern, flags) (stdout, cnt) = cp.subn('', stdout, count=count) if count == 0 or count - cnt > 0: stderr = cp.sub('', stderr, count=count - cnt) for pattern in ('exception', 'error', 'warning', 'fatal', 'traceback', 'fault', 'crash(?:ed)?', 'abort(?:ed)', 'fishy'): cp = re.compile(r'\b{}\b'.format(pattern), re.IGNORECASE | re.MULTILINE) hit = cp.search(stderr) if hit: raise AssertionError('Suspicious output to stderr (matched "%s")' % hit.group(0)) hit = cp.search(stdout) if hit: raise AssertionError('Suspicious output to stdout (matched "%s")' % hit.group(0)) def register_output(item, pattern, count=1, flags=re.MULTILINE): '''Register *pattern* as false positive for output checking This prevents the test from failing because the output otherwise appears suspicious. ''' item.checklogs_fp.append((pattern, flags, count)) @pytest.fixture() def reg_output(request): assert not hasattr(request.node, 'checklogs_fp') request.node.checklogs_fp = [] return functools.partial(register_output, request.node) def check_output(item): pm = item.config.pluginmanager cm = pm.getplugin('capturemanager') capmethod = (getattr(cm, '_capturing', None) or getattr(item, '_capture_fixture', None) or getattr(cm, '_global_capturing', None)) check_test_output(capmethod, item) check_test_log(item.catch_log_handler) @pytest.hookimpl(trylast=True) def pytest_runtest_setup(item): check_output(item) @pytest.hookimpl(trylast=True) def pytest_runtest_call(item): check_output(item) @pytest.hookimpl(trylast=True) def pytest_runtest_teardown(item, nextitem): check_output(item) llfuse-1.3.3/test/test_api.py0000775000175000017500000000561713202301227017641 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' test_api.py - Unit tests for Python-LLFUSE. Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import if __name__ == '__main__': import pytest import sys sys.exit(pytest.main([__file__] + sys.argv[1:])) import llfuse import tempfile import os import errno import pytest from copy import copy from pickle import PicklingError def test_inquire_bits(): assert 0 < llfuse.get_ino_t_bits() < 256 assert 0 < llfuse.get_off_t_bits() < 256 def test_listdir(): # There is a race-condition here if /usr/bin is modified while the test # runs - but hopefully this is sufficiently rare. list1 = set(os.listdir('/usr/bin')) list2 = set(llfuse.listdir('/usr/bin')) assert list1 == list2 def test_sup_groups(): gids = llfuse.get_sup_groups(os.getpid()) gids2 = set(os.getgroups()) assert gids == gids2 def _getxattr_helper(path, name): try: value = llfuse.getxattr(path, name) except OSError as exc: errno = exc.errno value = None if not hasattr(os, 'getxattr'): return value try: value2 = os.getxattr(path, name) except OSError as exc: assert exc.errno == errno else: assert value2 is not None assert value2 == value return value def test_entry_res(): a = llfuse.EntryAttributes() val = 1000.2735 a.st_atime_ns = val*1e9 assert a.st_atime_ns / 1e9 == val def test_xattr(): with tempfile.NamedTemporaryFile() as fh: key = 'user.new_attribute' assert _getxattr_helper(fh.name, key) is None value = b'a nice little bytestring' try: llfuse.setxattr(fh.name, key, value) except OSError as exc: if exc.errno == errno.ENOTSUP: pytest.skip('ACLs not supported for %s' % fh.name) raise assert _getxattr_helper(fh.name, key) == value if not hasattr(os, 'setxattr'): return key = 'user.another_new_attribute' assert _getxattr_helper(fh.name, key) is None value = b'a nice little bytestring, but slightly modified' os.setxattr(fh.name, key, value) assert _getxattr_helper(fh.name, key) == value def test_copy(): for obj in (llfuse.SetattrFields(), llfuse.RequestContext(), llfuse.lock, llfuse.lock_released): pytest.raises(PicklingError, copy, obj) for (inst, attr) in ((llfuse.EntryAttributes(), 'st_mode'), (llfuse.StatvfsData(), 'f_files')): setattr(inst, attr, 42) inst_copy = copy(inst) assert getattr(inst, attr) == getattr(inst_copy, attr) inst = llfuse.FUSEError(10) assert inst.errno == copy(inst).errno llfuse-1.3.3/test/pytest.ini0000664000175000017500000000007512653313107017507 0ustar nikrationikratio00000000000000[pytest] addopts = --verbose --assert=rewrite --tb=native -x llfuse-1.3.3/test/util.py0000664000175000017500000000744513004543364017016 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' util.py - Utility functions for Python-LLFUSE unit tests. Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import import platform import subprocess import pytest import os import stat import time import sys # For Python 2 + 3 compatibility if sys.version_info[0] == 2: subprocess.DEVNULL = open('/dev/null', 'w') def fuse_test_marker(): '''Return a pytest.marker that indicates FUSE availability If system/user/environment does not support FUSE, return a `pytest.mark.skip` object with more details. If FUSE is supported, return `pytest.mark.uses_fuse()`. ''' if platform.system() == 'Darwin': # No working autodetection, just assume it will work. return skip = lambda x: pytest.mark.skip(reason=x) # Python 2.x: Popen is not a context manager... which = subprocess.Popen(['which', 'fusermount'], stdout=subprocess.PIPE, universal_newlines=True) try: fusermount_path = which.communicate()[0].strip() finally: which.wait() if not fusermount_path or which.returncode != 0: return skip("Can't find fusermount executable") if not os.path.exists('/dev/fuse'): return skip("FUSE kernel module does not seem to be loaded") if os.getuid() == 0: return pytest.mark.uses_fuse() mode = os.stat(fusermount_path).st_mode if mode & stat.S_ISUID == 0: return skip('fusermount executable not setuid, and we are not root.') try: fd = os.open('/dev/fuse', os.O_RDWR) except OSError as exc: return skip('Unable to open /dev/fuse: %s' % exc.strerror) else: os.close(fd) return pytest.mark.uses_fuse() def exitcode(process): if isinstance(process, subprocess.Popen): return process.poll() else: if process.is_alive(): return None else: return process.exitcode def wait_for(callable, timeout=10, interval=0.1): '''Wait until *callable* returns something True and return it If *timeout* expires, return None ''' waited = 0 while True: ret = callable() if ret: return ret if waited > timeout: return None waited += interval time.sleep(interval) def wait_for_mount(mount_process, mnt_dir): elapsed = 0 while elapsed < 30: if os.path.ismount(mnt_dir): return True if exitcode(mount_process) is not None: pytest.fail('file system process terminated prematurely') time.sleep(0.1) elapsed += 0.1 pytest.fail("mountpoint failed to come up") def cleanup(mnt_dir): if platform.system() == 'Darwin': subprocess.call(['umount', '-l', mnt_dir], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT) else: subprocess.call(['fusermount', '-z', '-u', mnt_dir], stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT) def umount(mount_process, mnt_dir): if platform.system() == 'Darwin': subprocess.check_call(['umount', '-l', mnt_dir]) else: subprocess.check_call(['fusermount', '-z', '-u', mnt_dir]) assert not os.path.ismount(mnt_dir) # Give mount process a little while to terminate. Popen.wait(timeout) # was only added in 3.3... elapsed = 0 while elapsed < 30: code = exitcode(mount_process) if code is not None: if code == 0: return pytest.fail('file system process terminated with code %s' % (code,)) time.sleep(0.1) elapsed += 0.1 pytest.fail('mount process did not terminate') llfuse-1.3.3/test/test_examples.py0000775000175000017500000002554613004536055020722 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' test_examples.py - Unit tests for Python-LLFUSE. Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import if __name__ == '__main__': import pytest import sys sys.exit(pytest.main([__file__] + sys.argv[1:])) import subprocess import os import sys import pytest import stat import shutil import filecmp import errno from tempfile import NamedTemporaryFile from util import fuse_test_marker, wait_for_mount, umount, cleanup basename = os.path.join(os.path.dirname(__file__), '..') TEST_FILE = __file__ pytestmark = fuse_test_marker() with open(TEST_FILE, 'rb') as fh: TEST_DATA = fh.read() def name_generator(__ctr=[0]): __ctr[0] += 1 return 'testfile_%d' % __ctr[0] def test_lltest(tmpdir): mnt_dir = str(tmpdir) cmdline = [sys.executable, os.path.join(basename, 'examples', 'lltest.py'), mnt_dir ] mount_process = subprocess.Popen(cmdline, stdin=subprocess.DEVNULL, universal_newlines=True) try: wait_for_mount(mount_process, mnt_dir) assert os.listdir(mnt_dir) == [ 'message' ] filename = os.path.join(mnt_dir, 'message') with open(filename, 'r') as fh: assert fh.read() == 'hello world\n' with pytest.raises(IOError) as exc_info: open(filename, 'r+') assert exc_info.value.errno == errno.EPERM with pytest.raises(IOError) as exc_info: open(filename + 'does-not-exist', 'r+') assert exc_info.value.errno == errno.ENOENT except: cleanup(mnt_dir) raise else: umount(mount_process, mnt_dir) def test_tmpfs(tmpdir): mnt_dir = str(tmpdir) cmdline = [sys.executable, os.path.join(basename, 'examples', 'tmpfs.py'), mnt_dir ] mount_process = subprocess.Popen(cmdline, stdin=subprocess.DEVNULL, universal_newlines=True) try: wait_for_mount(mount_process, mnt_dir) tst_write(mnt_dir) tst_mkdir(mnt_dir) tst_symlink(mnt_dir) tst_mknod(mnt_dir) tst_chown(mnt_dir) tst_chmod(mnt_dir) tst_utimens(mnt_dir) tst_link(mnt_dir) tst_readdir(mnt_dir) tst_statvfs(mnt_dir) tst_truncate_path(mnt_dir) tst_truncate_fd(mnt_dir) tst_unlink(mnt_dir) except: cleanup(mnt_dir) raise else: umount(mount_process, mnt_dir) @pytest.mark.skipif(sys.version_info < (3,3), reason="requires python3.3") def test_passthroughfs(tmpdir): mnt_dir = str(tmpdir.mkdir('mnt')) src_dir = str(tmpdir.mkdir('src')) cmdline = [sys.executable, os.path.join(basename, 'examples', 'passthroughfs.py'), src_dir, mnt_dir ] mount_process = subprocess.Popen(cmdline, stdin=subprocess.DEVNULL, universal_newlines=True) try: wait_for_mount(mount_process, mnt_dir) tst_write(mnt_dir) tst_mkdir(mnt_dir) tst_symlink(mnt_dir) tst_mknod(mnt_dir) if os.getuid() == 0: tst_chown(mnt_dir) tst_chmod(mnt_dir) # Underlying fs may not have full nanosecond resolution tst_utimens(mnt_dir, ns_tol=1000) tst_link(mnt_dir) tst_readdir(mnt_dir) tst_statvfs(mnt_dir) tst_truncate_path(mnt_dir) tst_truncate_fd(mnt_dir) tst_unlink(mnt_dir) tst_passthrough(src_dir, mnt_dir) except: cleanup(mnt_dir) raise else: umount(mount_process, mnt_dir) def checked_unlink(filename, path, isdir=False): fullname = os.path.join(path, filename) if isdir: os.rmdir(fullname) else: os.unlink(fullname) with pytest.raises(OSError) as exc_info: os.stat(fullname) assert exc_info.value.errno == errno.ENOENT assert filename not in os.listdir(path) def tst_mkdir(mnt_dir): dirname = name_generator() fullname = mnt_dir + "/" + dirname os.mkdir(fullname) fstat = os.stat(fullname) assert stat.S_ISDIR(fstat.st_mode) assert os.listdir(fullname) == [] assert fstat.st_nlink in (1,2) assert dirname in os.listdir(mnt_dir) checked_unlink(dirname, mnt_dir, isdir=True) def tst_symlink(mnt_dir): linkname = name_generator() fullname = mnt_dir + "/" + linkname os.symlink("/imaginary/dest", fullname) fstat = os.lstat(fullname) assert stat.S_ISLNK(fstat.st_mode) assert os.readlink(fullname) == "/imaginary/dest" assert fstat.st_nlink == 1 assert linkname in os.listdir(mnt_dir) checked_unlink(linkname, mnt_dir) def tst_mknod(mnt_dir): filename = os.path.join(mnt_dir, name_generator()) shutil.copyfile(TEST_FILE, filename) fstat = os.lstat(filename) assert stat.S_ISREG(fstat.st_mode) assert fstat.st_nlink == 1 assert os.path.basename(filename) in os.listdir(mnt_dir) assert filecmp.cmp(TEST_FILE, filename, False) checked_unlink(filename, mnt_dir) def tst_chown(mnt_dir): filename = os.path.join(mnt_dir, name_generator()) os.mkdir(filename) fstat = os.lstat(filename) uid = fstat.st_uid gid = fstat.st_gid uid_new = uid + 1 os.chown(filename, uid_new, -1) fstat = os.lstat(filename) assert fstat.st_uid == uid_new assert fstat.st_gid == gid gid_new = gid + 1 os.chown(filename, -1, gid_new) fstat = os.lstat(filename) assert fstat.st_uid == uid_new assert fstat.st_gid == gid_new checked_unlink(filename, mnt_dir, isdir=True) def tst_chmod(mnt_dir): filename = os.path.join(mnt_dir, name_generator()) os.mkdir(filename) fstat = os.lstat(filename) mode = stat.S_IMODE(fstat.st_mode) mode_new = 0o640 assert mode != mode_new os.chmod(filename, mode_new) fstat = os.lstat(filename) assert stat.S_IMODE(fstat.st_mode) == mode_new checked_unlink(filename, mnt_dir, isdir=True) def tst_write(mnt_dir): name = os.path.join(mnt_dir, name_generator()) shutil.copyfile(TEST_FILE, name) assert filecmp.cmp(name, TEST_FILE, False) checked_unlink(name, mnt_dir) def tst_unlink(mnt_dir): name = os.path.join(mnt_dir, name_generator()) data1 = b'foo' data2 = b'bar' with open(os.path.join(mnt_dir, name), 'wb+', buffering=0) as fh: fh.write(data1) checked_unlink(name, mnt_dir) fh.write(data2) fh.seek(0) assert fh.read() == data1+data2 def tst_statvfs(mnt_dir): os.statvfs(mnt_dir) def tst_link(mnt_dir): name1 = os.path.join(mnt_dir, name_generator()) name2 = os.path.join(mnt_dir, name_generator()) shutil.copyfile(TEST_FILE, name1) assert filecmp.cmp(name1, TEST_FILE, False) os.link(name1, name2) fstat1 = os.lstat(name1) fstat2 = os.lstat(name2) assert fstat1 == fstat2 assert fstat1.st_nlink == 2 assert os.path.basename(name2) in os.listdir(mnt_dir) assert filecmp.cmp(name1, name2, False) os.unlink(name2) fstat1 = os.lstat(name1) assert fstat1.st_nlink == 1 os.unlink(name1) def tst_readdir(mnt_dir): dir_ = os.path.join(mnt_dir, name_generator()) file_ = dir_ + "/" + name_generator() subdir = dir_ + "/" + name_generator() subfile = subdir + "/" + name_generator() os.mkdir(dir_) shutil.copyfile(TEST_FILE, file_) os.mkdir(subdir) shutil.copyfile(TEST_FILE, subfile) listdir_is = os.listdir(dir_) listdir_is.sort() listdir_should = [ os.path.basename(file_), os.path.basename(subdir) ] listdir_should.sort() assert listdir_is == listdir_should os.unlink(file_) os.unlink(subfile) os.rmdir(subdir) os.rmdir(dir_) def tst_truncate_path(mnt_dir): if sys.version_info < (3,0): # 2.x has no os.truncate return assert len(TEST_DATA) > 1024 filename = os.path.join(mnt_dir, name_generator()) with open(filename, 'wb') as fh: fh.write(TEST_DATA) fstat = os.stat(filename) size = fstat.st_size assert size == len(TEST_DATA) # Add zeros at the end os.truncate(filename, size + 1024) assert os.stat(filename).st_size == size + 1024 with open(filename, 'rb') as fh: assert fh.read(size) == TEST_DATA assert fh.read(1025) == b'\0' * 1024 # Truncate data os.truncate(filename, size - 1024) assert os.stat(filename).st_size == size - 1024 with open(filename, 'rb') as fh: assert fh.read(size) == TEST_DATA[:size-1024] os.unlink(filename) def tst_truncate_fd(mnt_dir): assert len(TEST_DATA) > 1024 with NamedTemporaryFile('w+b', 0, dir=mnt_dir) as fh: fd = fh.fileno() fh.write(TEST_DATA) fstat = os.fstat(fd) size = fstat.st_size assert size == len(TEST_DATA) # Add zeros at the end os.ftruncate(fd, size + 1024) assert os.fstat(fd).st_size == size + 1024 fh.seek(0) assert fh.read(size) == TEST_DATA assert fh.read(1025) == b'\0' * 1024 # Truncate data os.ftruncate(fd, size - 1024) assert os.fstat(fd).st_size == size - 1024 fh.seek(0) assert fh.read(size) == TEST_DATA[:size-1024] def tst_utimens(mnt_dir, ns_tol=0): filename = os.path.join(mnt_dir, name_generator()) os.mkdir(filename) fstat = os.lstat(filename) atime = fstat.st_atime + 42.28 mtime = fstat.st_mtime - 42.23 if sys.version_info < (3,3): os.utime(filename, (atime, mtime)) else: atime_ns = fstat.st_atime_ns + int(42.28*1e9) mtime_ns = fstat.st_mtime_ns - int(42.23*1e9) os.utime(filename, None, ns=(atime_ns, mtime_ns)) fstat = os.lstat(filename) assert abs(fstat.st_atime - atime) < 1e-3 assert abs(fstat.st_mtime - mtime) < 1e-3 if sys.version_info >= (3,3): assert abs(fstat.st_atime_ns - atime_ns) <= ns_tol assert abs(fstat.st_mtime_ns - mtime_ns) <= ns_tol checked_unlink(filename, mnt_dir, isdir=True) def tst_passthrough(src_dir, mnt_dir): name = name_generator() src_name = os.path.join(src_dir, name) mnt_name = os.path.join(src_dir, name) assert name not in os.listdir(src_dir) assert name not in os.listdir(mnt_dir) with open(src_name, 'w') as fh: fh.write('Hello, world') assert name in os.listdir(src_dir) assert name in os.listdir(mnt_dir) assert os.stat(src_name) == os.stat(mnt_name) name = name_generator() src_name = os.path.join(src_dir, name) mnt_name = os.path.join(src_dir, name) assert name not in os.listdir(src_dir) assert name not in os.listdir(mnt_dir) with open(mnt_name, 'w') as fh: fh.write('Hello, world') assert name in os.listdir(src_dir) assert name in os.listdir(mnt_dir) assert os.stat(src_name) == os.stat(mnt_name) llfuse-1.3.3/test/conftest.py0000644000175000017500000000710212720723015017647 0ustar nikrationikratio00000000000000import sys import os.path import logging import pytest import time import gc # Enable output checks pytest_plugins = ('pytest_checklogs') # Register false positives @pytest.fixture(autouse=True) def register_false_checklog_pos(reg_output): # DeprecationWarnings are unfortunately quite often a result of indirect # imports via third party modules, so we can't actually fix them. reg_output(r'(Pending)?DeprecationWarning', count=0) # Valgrind output reg_output(r'^==\d+== Memcheck, a memory error detector$') reg_output(r'^==\d+== For counts of detected and suppressed errors, rerun with: -v') reg_output(r'^==\d+== ERROR SUMMARY: 0 errors from 0 contexts') def pytest_addoption(parser): group = parser.getgroup("general") group._addoption("--installed", action="store_true", default=False, help="Test the installed package.") group = parser.getgroup("terminal reporting") group._addoption("--logdebug", action="append", metavar='', help="Activate debugging output from for tests. Use `all` " "to get debug messages from all modules. This option can be " "specified multiple times.") # If a test fails, wait a moment before retrieving the captured # stdout/stderr. When using a server process, this makes sure that we capture # any potential output of the server that comes *after* a test has failed. For # example, if a request handler raises an exception, the server first signals an # error to FUSE (causing the test to fail), and then logs the exception. Without # the extra delay, the exception will go into nowhere. @pytest.mark.hookwrapper def pytest_pyfunc_call(pyfuncitem): outcome = yield failed = outcome.excinfo is not None if failed: time.sleep(1) def pytest_configure(config): # If we are running from the source directory, make sure that we load # modules from here basedir = os.path.abspath(os.path.join(os.path.dirname(__file__), '..')) if not config.getoption('installed'): llfuse_path = os.path.join(basedir, 'src') if (os.path.exists(os.path.join(basedir, 'setup.py')) and os.path.exists(os.path.join(basedir, 'src', 'llfuse.pyx'))): sys.path.insert(0, llfuse_path) # Make sure that called processes use the same path pp = os.environ.get('PYTHONPATH', None) if pp: pp = '%s:%s' % (llfuse_path, pp) else: pp = llfuse_path os.environ['PYTHONPATH'] = pp try: import faulthandler except ImportError: pass else: faulthandler.enable() # When running from VCS repo, enable all warnings if os.path.exists(os.path.join(basedir, 'MANIFEST.in')): import warnings warnings.resetwarnings() warnings.simplefilter('default') # Configure logging. We don't set a default handler but rely on # the catchlog pytest plugin. logdebug = config.getoption('logdebug') root_logger = logging.getLogger() if logdebug is not None: logging.disable(logging.NOTSET) if 'all' in logdebug: root_logger.setLevel(logging.DEBUG) else: for module in logdebug: logging.getLogger(module).setLevel(logging.DEBUG) else: root_logger.setLevel(logging.INFO) logging.disable(logging.DEBUG) logging.captureWarnings(capture=True) # Run gc.collect() at the end of every test, so that we get ResourceWarnings # as early as possible. def pytest_runtest_teardown(item, nextitem): gc.collect() llfuse-1.3.3/doc/0000775000175000017500000000000013257663654015262 5ustar nikrationikratio00000000000000llfuse-1.3.3/Changes.rst0000664000175000017500000002517213257657710016622 0ustar nikrationikratio00000000000000=========== Changelog =========== .. currentmodule:: llfuse Release 1.3.3 (2018-03-31) ========================== * Dropped pytest-catchlog dependency and add support for Pytest 3.3.0. * Minor bugfixes. Release 1.3.2 (2017-11-13) ========================== * Minor bugfixes. Release 1.3.1 (2017-09-22) ========================== * The main loop now terminates properly again when terminated by a signal. Release 1.3 (2017-09-15) ======================== * The `StatvfsData` class now has an `!~StatvfsData.f_namemax` attribute. * `EntryAttributes` and `StatvfsData` instances can now be pickled and copied. Other llfuse classes now raise an exception when the do not support pickling/copying. Release 1.2 (2017-01-22) ======================== * The *attr* argument of the `~Operations.setattr` handler now contains valid values only for the attributes that are to be set. Previously, the documentation assorted that other attributes would be set to the original (unchanged) values. However, that was actually never the case. Release 1.1.1 (2016-07-27) ========================== * Fixed the description of the `~Operations.lookup` handler (should return zero if there is no such entry, not a negative value). * Fixed the description of the `EntryAttributes` structure (descriptions of `~EntryAttributes.attr_timeout` and `~EntryAttributes.entry_timeout` were switched). Release 1.1 (2016-05-23) ======================== * Added support for nanosecond resolution time-stamps in GNU/kFreeBSD. * Fixed another set of build issues on FreeBSD. Release 1.0 (2016-03-08) ======================== **Note:** The 1.0 version number does not imply any special stability or an API freeze. It's a consequence of switching to semantic versioning, where backwards incompatible changes will always result in increased major version. * Fixed an overflow when accessing the ``*st_xtime_ns`` attributes of the `~llfuse.EntryAttributes` class from Python on 32-bit systems. * POTENTIAL COMPATIBILITY BREAK: The `~Operations.destroy` handler is now called with the global lock acquired. Release 0.43 (2016-02-23) ========================= * Fixed build-failure under OS-X. * Fixed some build failures under FreeBSD (hopefully all of them, but no testers were available before the release). * The *workers* parameter to `llfuse.main` may now be `None`. Release 0.42.1 (2016-02-01) =========================== * Include HTML documentation. Release 0.42 (2016-01-30) ========================= * The documentation has been clarified and extended - please take a look even if you're already familiar with Python-LLFUSE. * Extended coverage of unit tests. * Fixed a compile error under OS-X. * Added `notify_store` function. * Added `get_sup_groups` function. * The `~Operations.read` handler may now return arbitrary objects that as long as they implement the buffer protocol. * Implemented a *forget_multi* handler (used behind the scenes). * Many classes were rewritten in Cython for improved performance. * Python thread-specific data is now initialized only once rather than every time a handler is called. * SIGINT (Ctrl-C) now properly terminates `llfuse.main` also when running with multiple workers. * The return value of `llfuse.main` now indicates if the loop was terminated due to an unmount request or due to a signal. BACKWARDS INCOMPATIBLE CHANGES: * Ducktyping the `EntryAttributes` class is no longer allowed, `Operations` methods must return instances of this class (rather than any object that provides the necessary attributes). * The `!st_Xtime` attributes of the `EntryAttributes` have been dropped in favor of the `!st_Xtime_ns` attributes. * The `setattr` method now always receives a completely filled `EntryAttributes` instance. To determine which attributes should be changed, a new *fields* argument has been introduced. * The `~Operations.setattr` method now also receives an *fh* parameter. * The `llfuse.main` function now has a *workers* parameter, and the *single* parameter was dropped. * Almost all request handlers now receive a `RequestContext` instance in an additional parameter. Release 0.41.1 (2015-08-22) =========================== * Added some files in :file:`test/` that were missing in the 0.41 tarball. Tests now support the ``--installed`` option, produce prettier output, and check for error messages printed to stderr or stdout. * Python-LLFUSE can now also be built on NetBSD. * Added support for FUSE_SET_ATTR_ATIME_NOW and FUSE_SET_ATTR_MTIME_NOW setattr flags. Previously, these would be silently ignored. * Fixed an AssertionError in :file:`examples/passthroughfs.py` Release 0.41 (2015-08-20) ========================= * Fixed a syntax error in contrib/tmpfs.py * Introduced an `!llfuse.__version__` attribute. * Added more reasonable default values for `llfuse.EntryAttributes`. * Added new minimal example, :file:`examples/lltest.py`. * Added unit tests. * Added an example for a pass-through file system, :file:`examples/passthroughfs.py`. Release 0.40 (2013-11-26) ========================= * Re-raising an exception from a request handler now works correctly under Python 3. Problems were caused by a Cython bug, but llfuse now works around the issue. * File atime, ctime and mtime can now also be represented as nanosecond integer values for increased resolution. Thanks to nagy.attila@gmail.com for the initial patch. * Python-llfuse no longer includes the setuptools/distribute bootstrap script. This module thus has to be installed manually if not already present on the system. * Duck-typing of the Operations instance is now supported. * Python-llfuse no longer requires a re-compilation of the Cython code (setup.py build_cython step) when compiling for MacOS or FreeBSD. * Extended attributes are now properly supported under FreeBSD. Release 0.39 (2013-05-11) ========================= * When running under Python 3.x, several functions now work with string objects rather than byte objects: - llfuse.init(): the *mountpoint* argument, and the elements of the *fuse_opts* argument are expected to be of type str. - llfuse.listdir(): the *path* argument is expected to be of type str, and the values returned by the iterator will be of type str as well. - llfuse.getxattr(), llfuse.setxattr(): the *path* and *name* arguments are expected to be of type str. When necessary, values will be converted to the file system encoding using the surrogatescape handler as described in PEP 383 (http://www.python.org/dev/peps/pep-0383/) * Renamed get_off_t_bytes() and get_ino_t_bytes() to get_off_t_bits() and get_ino_t_bits() and documented them. Release 0.38 (2013-01-05) ========================= * Various small bugfixes. Release 0.37.1 (2011-12-10) =========================== * Fixed a segfault-causing race condition in Lock.acquire() and Lock.yield(). Release 0.37 (2011-12-05) ========================= * Explicitly call fuse_chan_destroy() in llfuse.close(), so that the mountpoint becomes inaccessible right away, even while the process is still running. * Added get_ino_t_bytes() and get_off_t_bytes() that return the number of bytes used for representing inode numbers and file offsets. * The yield_() method of the global lock now takes an additional *count* argument that can be used to yield the lock more than once. * Changed implementation of global lock. The global lock is no longer a mutex, but a boolean variable protected by a mutex, and changes are tracked with a condition object. This allows lock.yield() to work properly: if there are other threads waiting for the lock, they are guaranteed to run. If there are no other threads waiting for the lock, execution of the active thread continues immediately. The previous implementation using sched_yield() was mostly broken: threads trying to acquire the global lock were calling pthread_mutex_lock, so they got removed from the kernels runqueue. However, calls to sched_yield() would just put the active thread into the expired runqueue, and calls to pthread_mutex_unlock apparently do not synchronously move the threads waiting for the lock back to a runqueue. Therefore, most of the time the active thread would be the only thread in any runqueue and thus continue to run. * The Operations.forget() method now receives a list of (inode, nlookup) tuples rather than just one such tuple. * invalidate_entry() and invalidate_inode() no longer work synchronously. Instead, the message is put in a queue and send by a background thread. * The acquire() method of the global lock now has an optional *timeout* parameter. * The create() request handler now receives the open flags as an additional parameter. Release 0.36 (2011-09-20) ========================= * Don't send SIGHUP if exception is encountered in destroy() handler (since at that point, main loop has already terminated and signal handling been reset). * Fix a problem with request handler exceptions being re-raised not only in llfuse.main(), but also in llfuse.close() when running single threaded. Release 0.35 (2011-09-14) ========================= * Explicitly initialize Python thread support. Previously, calling llfuse.main() resulted in a crash if no Python threads were used before the call. * Removed handle_exc() method. If request handle raise an exception, the main loop now terminates and the exception is re-raised and passed to the caller of llfuse.main(). * llfuse.close() can now leave the mountpoint in an inaccessible state to signal a shutdown due to an internal file system error. * The destroy() request handler is now called without the global lock acquired. This makes sense, because it's not called as part of the main loop but by llfuse.close(). Release 0.34 (2011-08-10) ========================= * Explicitly cast S_* constants to mode_t to prevent compiler warnings on FreeBSD. * Fixed initialization error under Python 3. Release 0.33 (2011-07-03) ========================= * Various small bugfixes. Release 0.32 (2011-06-04) ========================= * Fixed unlink() bug in contrib/example.py * Include :file:`src/*.pxi` files in release tarball. Were accidentally omitted in previous version. * Moved debian/ directory into separate repository. Release 0.31 (2011-05-12) ========================= * Use long for storing nanoseconds in file [amc]times, not int. Release 0.30 (2011-03-08) ========================= * Fixed compile errors with Python 3.0 and 3.1. * Fixed error handling, errno is now read correctly. * Documentation is now shipped in tarball rather than generated during installation. Release 0.29 (2010-12-30) ========================= * Initial release llfuse-1.3.3/Include/0000775000175000017500000000000013257663654016100 5ustar nikrationikratio00000000000000llfuse-1.3.3/Include/fuse_lowlevel.pxd0000664000175000017500000001746313156755557021505 0ustar nikrationikratio00000000000000''' fuse_lowlevel.pxd This file contains Cython definitions for fuse_lowlevel.h Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from fuse_common cimport * from posix.stat cimport * from posix.types cimport * from libc.sys.statvfs cimport * from libc.stdlib cimport const_char from libc.stdint cimport uint32_t # Based on fuse sources, revision tag fuse_2_9_4 cdef extern from "" nogil: int FUSE_ROOT_ID ctypedef int fuse_ino_t ctypedef struct fuse_req: pass ctypedef fuse_req* fuse_req_t ctypedef int ulong_t "unsigned long" struct fuse_entry_param: fuse_ino_t ino unsigned long generation struct_stat attr double attr_timeout double entry_timeout struct fuse_ctx: uid_t uid gid_t gid pid_t pid mode_t umask struct fuse_forget_data: uint64_t ino uint64_t nlookup ctypedef fuse_ctx const_fuse_ctx "const struct fuse_ctx" int FUSE_SET_ATTR_MODE int FUSE_SET_ATTR_UID int FUSE_SET_ATTR_GID int FUSE_SET_ATTR_SIZE int FUSE_SET_ATTR_ATIME int FUSE_SET_ATTR_MTIME int FUSE_SET_ATTR_ATIME_NOW int FUSE_SET_ATTR_MTIME_NOW struct fuse_lowlevel_ops: void (*init) (void *userdata, fuse_conn_info *conn) void (*destroy) (void *userdata) void (*lookup) (fuse_req_t req, fuse_ino_t parent, const_char *name) void (*forget) (fuse_req_t req, fuse_ino_t ino, ulong_t nlookup) void (*getattr) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*setattr) (fuse_req_t req, fuse_ino_t ino, struct_stat *attr, int to_set, fuse_file_info *fi) void (*readlink) (fuse_req_t req, fuse_ino_t ino) void (*mknod) (fuse_req_t req, fuse_ino_t parent, const_char *name, mode_t mode, dev_t rdev) void (*mkdir) (fuse_req_t req, fuse_ino_t parent, const_char *name, mode_t mode) void (*unlink) (fuse_req_t req, fuse_ino_t parent, const_char *name) void (*rmdir) (fuse_req_t req, fuse_ino_t parent, const_char *name) void (*symlink) (fuse_req_t req, const_char *link, fuse_ino_t parent, const_char *name) void (*rename) (fuse_req_t req, fuse_ino_t parent, const_char *name, fuse_ino_t newparent, const_char *newname) void (*link) (fuse_req_t req, fuse_ino_t ino, fuse_ino_t newparent, const_char *newname) void (*open) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*read) (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, fuse_file_info *fi) void (*write) (fuse_req_t req, fuse_ino_t ino, const_char *buf, size_t size, off_t off, fuse_file_info *fi) void (*flush) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*release) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*fsync) (fuse_req_t req, fuse_ino_t ino, int datasync, fuse_file_info *fi) void (*opendir) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*readdir) (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, fuse_file_info *fi) void (*releasedir) (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) void (*fsyncdir) (fuse_req_t req, fuse_ino_t ino, int datasync, fuse_file_info *fi) void (*statfs) (fuse_req_t req, fuse_ino_t ino) void (*setxattr) (fuse_req_t req, fuse_ino_t ino, const_char *name, const_char *value, size_t size, int flags) void (*getxattr) (fuse_req_t req, fuse_ino_t ino, const_char *name, size_t size) void (*listxattr) (fuse_req_t req, fuse_ino_t ino, size_t size) void (*removexattr) (fuse_req_t req, fuse_ino_t ino, const_char *name) void (*access) (fuse_req_t req, fuse_ino_t ino, int mask) void (*create) (fuse_req_t req, fuse_ino_t parent, const_char *name, mode_t mode, fuse_file_info *fi) void (*write_buf) (fuse_req_t req, fuse_ino_t ino, fuse_bufvec *bufv, off_t off, fuse_file_info *fi) void (*retrieve_reply) (fuse_req_t req, void *cookie, fuse_ino_t ino, off_t offset, fuse_bufvec *bufv) void (*forget_multi) (fuse_req_t req, size_t count, fuse_forget_data *forgets) void (*fallocate) (fuse_req_t req, fuse_ino_t ino, int mode, off_t offset, off_t length, fuse_file_info *fi) int fuse_reply_err(fuse_req_t req, int err) void fuse_reply_none(fuse_req_t req) int fuse_reply_entry(fuse_req_t req, fuse_entry_param *e) int fuse_reply_create(fuse_req_t req, fuse_entry_param *e, fuse_file_info *fi) int fuse_reply_attr(fuse_req_t req, struct_stat *attr, double attr_timeout) int fuse_reply_readlink(fuse_req_t req, const_char *link) int fuse_reply_open(fuse_req_t req, fuse_file_info *fi) int fuse_reply_write(fuse_req_t req, size_t count) int fuse_reply_buf(fuse_req_t req, const_char *buf, size_t size) int fuse_reply_data(fuse_req_t req, fuse_bufvec *bufv, fuse_buf_copy_flags flags) int fuse_reply_statfs(fuse_req_t req, statvfs *stbuf) int fuse_reply_xattr(fuse_req_t req, size_t count) size_t fuse_add_direntry(fuse_req_t req, const_char *buf, size_t bufsize, const_char *name, struct_stat *stbuf, off_t off) int fuse_lowlevel_notify_inval_inode(fuse_chan *ch, fuse_ino_t ino, off_t off, off_t len) int fuse_lowlevel_notify_inval_entry(fuse_chan *ch, fuse_ino_t parent, const_char *name, size_t namelen) int fuse_lowlevel_notify_delete(fuse_chan *ch, fuse_ino_t parent, fuse_ino_t child, const_char *name, size_t namelen) int fuse_lowlevel_notify_store(fuse_chan *ch, fuse_ino_t ino, off_t offset, fuse_bufvec *bufv, fuse_buf_copy_flags flags) int fuse_lowlevel_notify_retrieve(fuse_chan *ch, fuse_ino_t ino, size_t size, off_t offset, void *cookie); void *fuse_req_userdata(fuse_req_t req) fuse_ctx *fuse_req_ctx(fuse_req_t req) int fuse_req_getgroups(fuse_req_t req, size_t size, gid_t list[]) fuse_session *fuse_lowlevel_new(fuse_args *args, fuse_lowlevel_ops *op, size_t op_size, void *userdata) struct fuse_session_ops: pass fuse_session *fuse_session_new(fuse_session_ops *op, void *data) void fuse_session_add_chan(fuse_session *se, fuse_chan *ch) int fuse_session_receive_buf(fuse_session *se, fuse_buf *buf, fuse_chan **chp) void fuse_session_process_buf(fuse_session *se, fuse_buf *buf, fuse_chan *ch) void fuse_session_remove_chan(fuse_chan *ch) void fuse_session_reset(fuse_session *se) void fuse_session_exit(fuse_session *se) void fuse_session_destroy(fuse_session *se) int fuse_session_loop(fuse_session *se) int fuse_session_loop_mt(fuse_session *se) void fuse_chan_destroy(fuse_chan *ch) size_t fuse_chan_bufsize(fuse_chan *ch) int fuse_session_exited(fuse_session *se) llfuse-1.3.3/Include/pthread.pxd0000664000175000017500000000336713202301227020224 0ustar nikrationikratio00000000000000''' pthreads.pxd This file contains Cython definitions for pthread.h Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from posix.signal cimport sigset_t cdef extern from "" nogil: # POSIX says this might be a struct, but CPython (and llfuse) # rely on it being an integer. ctypedef int pthread_t ctypedef struct pthread_attr_t: pass ctypedef struct pthread_mutexattr_t: pass ctypedef struct pthread_mutex_t: pass enum: PTHREAD_CANCEL_ENABLE PTHREAD_CANCEL_DISABLE int pthread_cancel(pthread_t thread) int pthread_setcancelstate(int state, int *oldstate) pthread_t pthread_self() int pthread_sigmask(int how, sigset_t *set, sigset_t *oldset) int pthread_equal(pthread_t t1, pthread_t t2) int pthread_create(pthread_t *thread, pthread_attr_t *attr, void *(*start_routine) (void *), void *arg) int pthread_join(pthread_t thread, void **retval) int pthread_kill(pthread_t thread, int sig) int pthread_mutex_init(pthread_mutex_t *mutex, pthread_mutexattr_t *mutexattr) int pthread_mutex_lock(pthread_mutex_t *mutex) int pthread_mutex_unlock(pthread_mutex_t *mutex) # The sem_* functions actually need the semaphone.h header file. However, under # OS-X we use a compatibility layer that breaks if we include the native # semaphore.h file. Therefore, we pretend that no header file is required and # conditionally include semaphore.h in llfuse.h. cdef extern from * nogil: ctypedef struct sem_t: pass int sem_init(sem_t *sem, int pshared, unsigned int value) int sem_post(sem_t *sem) int sem_wait(sem_t *sem) llfuse-1.3.3/Include/libc/0000775000175000017500000000000013257663654017011 5ustar nikrationikratio00000000000000llfuse-1.3.3/Include/libc/sys/0000775000175000017500000000000013257663654017627 5ustar nikrationikratio00000000000000llfuse-1.3.3/Include/libc/sys/__init__.py0000644000175000017500000000001512557224042021714 0ustar nikrationikratio00000000000000# Empty file llfuse-1.3.3/Include/libc/sys/statvfs.pxd0000664000175000017500000000116313202301227022006 0ustar nikrationikratio00000000000000''' statvfs.pxd This file contains Cython definitions for sys/statvfs.h Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' cdef extern from "" nogil: ctypedef int fsblkcnt_t ctypedef int fsfilcnt_t struct statvfs: unsigned long f_bsize unsigned long f_frsize fsblkcnt_t f_blocks fsblkcnt_t f_bfree fsblkcnt_t f_bavail fsfilcnt_t f_files fsfilcnt_t f_ffree fsfilcnt_t f_favail unsigned long f_namemax llfuse-1.3.3/Include/libc/dirent.pxd0000644000175000017500000000104212654245112020767 0ustar nikrationikratio00000000000000''' dirent.pxd This file contains Cython definitions for dirent.h and sys/types.h Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' cdef extern from "" nogil: ctypedef struct DIR: pass cdef struct dirent: char* d_name dirent* readdir(DIR* dirp) int readdir_r(DIR *dirp, dirent *entry, dirent **result) cdef extern from "" nogil: DIR *opendir(char *name) int closedir(DIR* dirp) llfuse-1.3.3/Include/libc/__init__.py0000644000175000017500000000001512557224042021076 0ustar nikrationikratio00000000000000# Empty file llfuse-1.3.3/Include/fuse_opt.pxd0000644000175000017500000000061112654245112020416 0ustar nikrationikratio00000000000000''' fuse_opt.pxd This file contains Cython definitions for fuse_opt.h Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' # Based on fuse sources, revision tag fuse_2_8_3 cdef extern from "" nogil: struct fuse_args: int argc char **argv int allocated llfuse-1.3.3/Include/fuse_common.pxd0000664000175000017500000000345712653313107021120 0ustar nikrationikratio00000000000000''' fuse_common.pxd This file contains Cython definitions for fuse_common.h Copyright © 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from fuse_opt cimport * from posix.types cimport off_t from libc.stdint cimport uint64_t # Based on fuse sources, revision tag fuse_2_9_4 cdef extern from * nogil: # fuse_common.h should not be included struct fuse_file_info: int flags unsigned int direct_io unsigned int keep_cache unsigned int nonseekable uint64_t fh uint64_t lock_owner struct fuse_conn_info: pass struct fuse_session: pass struct fuse_chan: pass fuse_chan *fuse_mount(char *mountpoint, fuse_args *args) void fuse_unmount(char *mountpoint, fuse_chan *ch) int fuse_set_signal_handlers(fuse_session *se) void fuse_remove_signal_handlers(fuse_session *se) # fuse_common.h declares these as enums, but they are # actually flags (i.e., FUSE_BUF_IS_FD|FUSE_BUF_FD_SEEK) # is a valid variable. Therefore, we declare the type # as integer instead. ctypedef int fuse_buf_flags enum: FUSE_BUF_IS_FD FUSE_BUF_FD_SEEK FUSE_BUF_FD_RETRY ctypedef int fuse_buf_copy_flags enum: FUSE_BUF_NO_SPLICE FUSE_BUF_FORCE_SPLICE FUSE_BUF_SPLICE_MOVE FUSE_BUF_SPLICE_NONBLOCK struct fuse_buf: size_t size fuse_buf_flags flags void *mem int fd off_t pos struct fuse_bufvec: size_t count size_t idx size_t off fuse_buf buf[1] size_t fuse_buf_size(fuse_bufvec *bufv) ssize_t fuse_buf_copy(fuse_bufvec *dst, fuse_bufvec *src, fuse_buf_copy_flags flags) llfuse-1.3.3/examples/0000775000175000017500000000000013257663654016333 5ustar nikrationikratio00000000000000llfuse-1.3.3/examples/lltest.py0000775000175000017500000001206313202301227020170 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' lltest.py - Example file system for Python-LLFUSE. This program presents a static file system containing a single file. It is compatible with both Python 2.x and 3.x. Based on an example from Gerion Entrup. Copyright © 2015 Nikolaus Rath Copyright © 2015 Gerion Entrup. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ''' from __future__ import division, print_function, absolute_import import os import sys # If we are running from the Python-LLFUSE source directory, try # to load the module from there first. basedir = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), '..')) if (os.path.exists(os.path.join(basedir, 'setup.py')) and os.path.exists(os.path.join(basedir, 'src', 'llfuse.pyx'))): sys.path.insert(0, os.path.join(basedir, 'src')) from argparse import ArgumentParser import stat import logging import errno import llfuse try: import faulthandler except ImportError: pass else: faulthandler.enable() log = logging.getLogger(__name__) class TestFs(llfuse.Operations): def __init__(self): super(TestFs, self).__init__() self.hello_name = b"message" self.hello_inode = llfuse.ROOT_INODE+1 self.hello_data = b"hello world\n" def getattr(self, inode, ctx=None): entry = llfuse.EntryAttributes() if inode == llfuse.ROOT_INODE: entry.st_mode = (stat.S_IFDIR | 0o755) entry.st_size = 0 elif inode == self.hello_inode: entry.st_mode = (stat.S_IFREG | 0o644) entry.st_size = len(self.hello_data) else: raise llfuse.FUSEError(errno.ENOENT) stamp = int(1438467123.985654 * 1e9) entry.st_atime_ns = stamp entry.st_ctime_ns = stamp entry.st_mtime_ns = stamp entry.st_gid = os.getgid() entry.st_uid = os.getuid() entry.st_ino = inode return entry def lookup(self, parent_inode, name, ctx=None): if parent_inode != llfuse.ROOT_INODE or name != self.hello_name: raise llfuse.FUSEError(errno.ENOENT) return self.getattr(self.hello_inode) def opendir(self, inode, ctx): if inode != llfuse.ROOT_INODE: raise llfuse.FUSEError(errno.ENOENT) return inode def readdir(self, fh, off): assert fh == llfuse.ROOT_INODE # only one entry if off == 0: yield (self.hello_name, self.getattr(self.hello_inode), 1) def open(self, inode, flags, ctx): if inode != self.hello_inode: raise llfuse.FUSEError(errno.ENOENT) if flags & os.O_RDWR or flags & os.O_WRONLY: raise llfuse.FUSEError(errno.EPERM) return inode def read(self, fh, off, size): assert fh == self.hello_inode return self.hello_data[off:off+size] def init_logging(debug=False): formatter = logging.Formatter('%(asctime)s.%(msecs)03d %(threadName)s: ' '[%(name)s] %(message)s', datefmt="%Y-%m-%d %H:%M:%S") handler = logging.StreamHandler() handler.setFormatter(formatter) root_logger = logging.getLogger() if debug: handler.setLevel(logging.DEBUG) root_logger.setLevel(logging.DEBUG) else: handler.setLevel(logging.INFO) root_logger.setLevel(logging.INFO) root_logger.addHandler(handler) def parse_args(): '''Parse command line''' parser = ArgumentParser() parser.add_argument('mountpoint', type=str, help='Where to mount the file system') parser.add_argument('--debug', action='store_true', default=False, help='Enable debugging output') parser.add_argument('--debug-fuse', action='store_true', default=False, help='Enable FUSE debugging output') return parser.parse_args() def main(): options = parse_args() init_logging(options.debug) testfs = TestFs() fuse_options = set(llfuse.default_options) fuse_options.add('fsname=lltest') if options.debug_fuse: fuse_options.add('debug') llfuse.init(testfs, options.mountpoint, fuse_options) try: llfuse.main(workers=1) except: llfuse.close(unmount=False) raise llfuse.close() if __name__ == '__main__': main() llfuse-1.3.3/examples/tmpfs.py0000775000175000017500000003730613202301227020021 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 # -*- coding: utf-8 -*- ''' tmpfs.py - Example file system for Python-LLFUSE. This file system stores all data in memory. It is compatible with both Python 2.x and 3.x. Copyright © 2013 Nikolaus Rath Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ''' from __future__ import division, print_function, absolute_import import os import sys # If we are running from the Python-LLFUSE source directory, try # to load the module from there first. basedir = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), '..')) if (os.path.exists(os.path.join(basedir, 'setup.py')) and os.path.exists(os.path.join(basedir, 'src', 'llfuse.pyx'))): sys.path.insert(0, os.path.join(basedir, 'src')) import llfuse import errno import stat from time import time import sqlite3 import logging from collections import defaultdict from llfuse import FUSEError from argparse import ArgumentParser try: import faulthandler except ImportError: pass else: faulthandler.enable() log = logging.getLogger() # For Python 2 + 3 compatibility if sys.version_info[0] == 2: def next(it): return it.next() else: buffer = memoryview class Operations(llfuse.Operations): '''An example filesystem that stores all data in memory This is a very simple implementation with terrible performance. Don't try to store significant amounts of data. Also, there are some other flaws that have not been fixed to keep the code easier to understand: * atime, mtime and ctime are not updated * generation numbers are not supported ''' def __init__(self): super(Operations, self).__init__() self.db = sqlite3.connect(':memory:') self.db.text_factory = str self.db.row_factory = sqlite3.Row self.cursor = self.db.cursor() self.inode_open_count = defaultdict(int) self.init_tables() def init_tables(self): '''Initialize file system tables''' self.cursor.execute(""" CREATE TABLE inodes ( id INTEGER PRIMARY KEY, uid INT NOT NULL, gid INT NOT NULL, mode INT NOT NULL, mtime_ns INT NOT NULL, atime_ns INT NOT NULL, ctime_ns INT NOT NULL, target BLOB(256) , size INT NOT NULL DEFAULT 0, rdev INT NOT NULL DEFAULT 0, data BLOB ) """) self.cursor.execute(""" CREATE TABLE contents ( rowid INTEGER PRIMARY KEY AUTOINCREMENT, name BLOB(256) NOT NULL, inode INT NOT NULL REFERENCES inodes(id), parent_inode INT NOT NULL REFERENCES inodes(id), UNIQUE (name, parent_inode) )""") # Insert root directory now_ns = int(time() * 1e9) self.cursor.execute("INSERT INTO inodes (id,mode,uid,gid,mtime_ns,atime_ns,ctime_ns) " "VALUES (?,?,?,?,?,?,?)", (llfuse.ROOT_INODE, stat.S_IFDIR | stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR | stat.S_IRGRP | stat.S_IXGRP | stat.S_IROTH | stat.S_IXOTH, os.getuid(), os.getgid(), now_ns, now_ns, now_ns)) self.cursor.execute("INSERT INTO contents (name, parent_inode, inode) VALUES (?,?,?)", (b'..', llfuse.ROOT_INODE, llfuse.ROOT_INODE)) def get_row(self, *a, **kw): self.cursor.execute(*a, **kw) try: row = next(self.cursor) except StopIteration: raise NoSuchRowError() try: next(self.cursor) except StopIteration: pass else: raise NoUniqueValueError() return row def lookup(self, inode_p, name, ctx=None): if name == '.': inode = inode_p elif name == '..': inode = self.get_row("SELECT * FROM contents WHERE inode=?", (inode_p,))['parent_inode'] else: try: inode = self.get_row("SELECT * FROM contents WHERE name=? AND parent_inode=?", (name, inode_p))['inode'] except NoSuchRowError: raise(llfuse.FUSEError(errno.ENOENT)) return self.getattr(inode, ctx) def getattr(self, inode, ctx=None): row = self.get_row('SELECT * FROM inodes WHERE id=?', (inode,)) entry = llfuse.EntryAttributes() entry.st_ino = inode entry.generation = 0 entry.entry_timeout = 300 entry.attr_timeout = 300 entry.st_mode = row['mode'] entry.st_nlink = self.get_row("SELECT COUNT(inode) FROM contents WHERE inode=?", (inode,))[0] entry.st_uid = row['uid'] entry.st_gid = row['gid'] entry.st_rdev = row['rdev'] entry.st_size = row['size'] entry.st_blksize = 512 entry.st_blocks = 1 entry.st_atime_ns = row['atime_ns'] entry.st_mtime_ns = row['mtime_ns'] entry.st_ctime_ns = row['ctime_ns'] return entry def readlink(self, inode, ctx): return self.get_row('SELECT * FROM inodes WHERE id=?', (inode,))['target'] def opendir(self, inode, ctx): return inode def readdir(self, inode, off): if off == 0: off = -1 cursor2 = self.db.cursor() cursor2.execute("SELECT * FROM contents WHERE parent_inode=? " 'AND rowid > ? ORDER BY rowid', (inode, off)) for row in cursor2: yield (row['name'], self.getattr(row['inode']), row['rowid']) def unlink(self, inode_p, name,ctx): entry = self.lookup(inode_p, name) if stat.S_ISDIR(entry.st_mode): raise llfuse.FUSEError(errno.EISDIR) self._remove(inode_p, name, entry) def rmdir(self, inode_p, name, ctx): entry = self.lookup(inode_p, name) if not stat.S_ISDIR(entry.st_mode): raise llfuse.FUSEError(errno.ENOTDIR) self._remove(inode_p, name, entry) def _remove(self, inode_p, name, entry): if self.get_row("SELECT COUNT(inode) FROM contents WHERE parent_inode=?", (entry.st_ino,))[0] > 0: raise llfuse.FUSEError(errno.ENOTEMPTY) self.cursor.execute("DELETE FROM contents WHERE name=? AND parent_inode=?", (name, inode_p)) if entry.st_nlink == 1 and entry.st_ino not in self.inode_open_count: self.cursor.execute("DELETE FROM inodes WHERE id=?", (entry.st_ino,)) def symlink(self, inode_p, name, target, ctx): mode = (stat.S_IFLNK | stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR | stat.S_IRGRP | stat.S_IWGRP | stat.S_IXGRP | stat.S_IROTH | stat.S_IWOTH | stat.S_IXOTH) return self._create(inode_p, name, mode, ctx, target=target) def rename(self, inode_p_old, name_old, inode_p_new, name_new, ctx): entry_old = self.lookup(inode_p_old, name_old) try: entry_new = self.lookup(inode_p_new, name_new) except llfuse.FUSEError as exc: if exc.errno != errno.ENOENT: raise target_exists = False else: target_exists = True if target_exists: self._replace(inode_p_old, name_old, inode_p_new, name_new, entry_old, entry_new) else: self.cursor.execute("UPDATE contents SET name=?, parent_inode=? WHERE name=? " "AND parent_inode=?", (name_new, inode_p_new, name_old, inode_p_old)) def _replace(self, inode_p_old, name_old, inode_p_new, name_new, entry_old, entry_new): if self.get_row("SELECT COUNT(inode) FROM contents WHERE parent_inode=?", (entry_new.st_ino,))[0] > 0: raise llfuse.FUSEError(errno.ENOTEMPTY) self.cursor.execute("UPDATE contents SET inode=? WHERE name=? AND parent_inode=?", (entry_old.st_ino, name_new, inode_p_new)) self.db.execute('DELETE FROM contents WHERE name=? AND parent_inode=?', (name_old, inode_p_old)) if entry_new.st_nlink == 1 and entry_new.st_ino not in self.inode_open_count: self.cursor.execute("DELETE FROM inodes WHERE id=?", (entry_new.st_ino,)) def link(self, inode, new_inode_p, new_name, ctx): entry_p = self.getattr(new_inode_p) if entry_p.st_nlink == 0: log.warn('Attempted to create entry %s with unlinked parent %d', new_name, new_inode_p) raise FUSEError(errno.EINVAL) self.cursor.execute("INSERT INTO contents (name, inode, parent_inode) VALUES(?,?,?)", (new_name, inode, new_inode_p)) return self.getattr(inode) def setattr(self, inode, attr, fields, fh, ctx): if fields.update_size: data = self.get_row('SELECT data FROM inodes WHERE id=?', (inode,))[0] if data is None: data = b'' if len(data) < attr.st_size: data = data + b'\0' * (attr.st_size - len(data)) else: data = data[:attr.st_size] self.cursor.execute('UPDATE inodes SET data=?, size=? WHERE id=?', (buffer(data), attr.st_size, inode)) if fields.update_mode: self.cursor.execute('UPDATE inodes SET mode=? WHERE id=?', (attr.st_mode, inode)) if fields.update_uid: self.cursor.execute('UPDATE inodes SET uid=? WHERE id=?', (attr.st_uid, inode)) if fields.update_gid: self.cursor.execute('UPDATE inodes SET gid=? WHERE id=?', (attr.st_gid, inode)) if fields.update_atime: self.cursor.execute('UPDATE inodes SET atime_ns=? WHERE id=?', (attr.st_atime_ns, inode)) if fields.update_mtime: self.cursor.execute('UPDATE inodes SET mtime_ns=? WHERE id=?', (attr.st_mtime_ns, inode)) return self.getattr(inode) def mknod(self, inode_p, name, mode, rdev, ctx): return self._create(inode_p, name, mode, ctx, rdev=rdev) def mkdir(self, inode_p, name, mode, ctx): return self._create(inode_p, name, mode, ctx) def statfs(self, ctx): stat_ = llfuse.StatvfsData() stat_.f_bsize = 512 stat_.f_frsize = 512 size = self.get_row('SELECT SUM(size) FROM inodes')[0] stat_.f_blocks = size // stat_.f_frsize stat_.f_bfree = max(size // stat_.f_frsize, 1024) stat_.f_bavail = stat_.f_bfree inodes = self.get_row('SELECT COUNT(id) FROM inodes')[0] stat_.f_files = inodes stat_.f_ffree = max(inodes , 100) stat_.f_favail = stat_.f_ffree return stat_ def open(self, inode, flags, ctx): # Yeah, unused arguments #pylint: disable=W0613 self.inode_open_count[inode] += 1 # Use inodes as a file handles return inode def access(self, inode, mode, ctx): # Yeah, could be a function and has unused arguments #pylint: disable=R0201,W0613 return True def create(self, inode_parent, name, mode, flags, ctx): #pylint: disable=W0612 entry = self._create(inode_parent, name, mode, ctx) self.inode_open_count[entry.st_ino] += 1 return (entry.st_ino, entry) def _create(self, inode_p, name, mode, ctx, rdev=0, target=None): if self.getattr(inode_p).st_nlink == 0: log.warn('Attempted to create entry %s with unlinked parent %d', name, inode_p) raise FUSEError(errno.EINVAL) now_ns = int(time() * 1e9) self.cursor.execute('INSERT INTO inodes (uid, gid, mode, mtime_ns, atime_ns, ' 'ctime_ns, target, rdev) VALUES(?, ?, ?, ?, ?, ?, ?, ?)', (ctx.uid, ctx.gid, mode, now_ns, now_ns, now_ns, target, rdev)) inode = self.cursor.lastrowid self.db.execute("INSERT INTO contents(name, inode, parent_inode) VALUES(?,?,?)", (name, inode, inode_p)) return self.getattr(inode) def read(self, fh, offset, length): data = self.get_row('SELECT data FROM inodes WHERE id=?', (fh,))[0] if data is None: data = b'' return data[offset:offset+length] def write(self, fh, offset, buf): data = self.get_row('SELECT data FROM inodes WHERE id=?', (fh,))[0] if data is None: data = b'' data = data[:offset] + buf + data[offset+len(buf):] self.cursor.execute('UPDATE inodes SET data=?, size=? WHERE id=?', (buffer(data), len(data), fh)) return len(buf) def release(self, fh): self.inode_open_count[fh] -= 1 if self.inode_open_count[fh] == 0: del self.inode_open_count[fh] if self.getattr(fh).st_nlink == 0: self.cursor.execute("DELETE FROM inodes WHERE id=?", (fh,)) class NoUniqueValueError(Exception): def __str__(self): return 'Query generated more than 1 result row' class NoSuchRowError(Exception): def __str__(self): return 'Query produced 0 result rows' def init_logging(debug=False): formatter = logging.Formatter('%(asctime)s.%(msecs)03d %(threadName)s: ' '[%(name)s] %(message)s', datefmt="%Y-%m-%d %H:%M:%S") handler = logging.StreamHandler() handler.setFormatter(formatter) root_logger = logging.getLogger() if debug: handler.setLevel(logging.DEBUG) root_logger.setLevel(logging.DEBUG) else: handler.setLevel(logging.INFO) root_logger.setLevel(logging.INFO) root_logger.addHandler(handler) def parse_args(): '''Parse command line''' parser = ArgumentParser() parser.add_argument('mountpoint', type=str, help='Where to mount the file system') parser.add_argument('--debug', action='store_true', default=False, help='Enable debugging output') parser.add_argument('--debug-fuse', action='store_true', default=False, help='Enable FUSE debugging output') return parser.parse_args() if __name__ == '__main__': options = parse_args() init_logging(options.debug) operations = Operations() fuse_options = set(llfuse.default_options) fuse_options.add('fsname=tmpfs') fuse_options.discard('default_permissions') if options.debug_fuse: fuse_options.add('debug') llfuse.init(operations, options.mountpoint, fuse_options) # sqlite3 does not support multithreading try: llfuse.main(workers=1) except: llfuse.close(unmount=False) raise llfuse.close() llfuse-1.3.3/examples/passthroughfs.py0000775000175000017500000004031113202301227021556 0ustar nikrationikratio00000000000000#!/usr/bin/env python3 ''' passthroughfs.py - Example file system for Python-LLFUSE This file system mirrors the contents of a specified directory tree. It requires Python 3.3 (since Python 2.x does not support the follow_symlinks parameters for os.* functions). Caveats: * Inode generation numbers are not passed through but set to zero. * Block size (st_blksize) and number of allocated blocks (st_blocks) are not passed through. * Performance for large directories is not good, because the directory is always read completely. * There may be a way to break-out of the directory tree. * The readdir implementation is not fully POSIX compliant. If a directory contains hardlinks and is modified during a readdir call, readdir() may return some of the hardlinked files twice or omit them completely. * If you delete or rename files in the underlying file system, the passthrough file system will get confused. Copyright © Nikolaus Rath Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ''' import os import sys # If we are running from the Python-LLFUSE source directory, try # to load the module from there first. basedir = os.path.abspath(os.path.join(os.path.dirname(sys.argv[0]), '..')) if (os.path.exists(os.path.join(basedir, 'setup.py')) and os.path.exists(os.path.join(basedir, 'src', 'llfuse.pyx'))): sys.path.insert(0, os.path.join(basedir, 'src')) import llfuse from argparse import ArgumentParser import errno import logging import stat as stat_m from llfuse import FUSEError from os import fsencode, fsdecode from collections import defaultdict import faulthandler faulthandler.enable() log = logging.getLogger(__name__) class Operations(llfuse.Operations): def __init__(self, source): super().__init__() self._inode_path_map = { llfuse.ROOT_INODE: source } self._lookup_cnt = defaultdict(lambda : 0) self._fd_inode_map = dict() self._inode_fd_map = dict() self._fd_open_count = dict() def _inode_to_path(self, inode): try: val = self._inode_path_map[inode] except KeyError: raise FUSEError(errno.ENOENT) if isinstance(val, set): # In case of hardlinks, pick any path val = next(iter(val)) return val def _add_path(self, inode, path): log.debug('_add_path for %d, %s', inode, path) self._lookup_cnt[inode] += 1 # With hardlinks, one inode may map to multiple paths. if inode not in self._inode_path_map: self._inode_path_map[inode] = path return val = self._inode_path_map[inode] if isinstance(val, set): val.add(path) elif val != path: self._inode_path_map[inode] = { path, val } def forget(self, inode_list): for (inode, nlookup) in inode_list: if self._lookup_cnt[inode] > nlookup: self._lookup_cnt[inode] -= nlookup continue log.debug('forgetting about inode %d', inode) assert inode not in self._inode_fd_map del self._lookup_cnt[inode] try: del self._inode_path_map[inode] except KeyError: # may have been deleted pass def lookup(self, inode_p, name, ctx=None): name = fsdecode(name) log.debug('lookup for %s in %d', name, inode_p) path = os.path.join(self._inode_to_path(inode_p), name) attr = self._getattr(path=path) if name != '.' and name != '..': self._add_path(attr.st_ino, path) return attr def getattr(self, inode, ctx=None): if inode in self._inode_fd_map: return self._getattr(fd=self._inode_fd_map[inode]) else: return self._getattr(path=self._inode_to_path(inode)) def _getattr(self, path=None, fd=None): assert fd is None or path is None assert not(fd is None and path is None) try: if fd is None: stat = os.lstat(path) else: stat = os.fstat(fd) except OSError as exc: raise FUSEError(exc.errno) entry = llfuse.EntryAttributes() for attr in ('st_ino', 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', 'st_size', 'st_atime_ns', 'st_mtime_ns', 'st_ctime_ns'): setattr(entry, attr, getattr(stat, attr)) entry.generation = 0 entry.entry_timeout = 5 entry.attr_timeout = 5 entry.st_blksize = 512 entry.st_blocks = ((entry.st_size+entry.st_blksize-1) // entry.st_blksize) return entry def readlink(self, inode, ctx): path = self._inode_to_path(inode) try: target = os.readlink(path) except OSError as exc: raise FUSEError(exc.errno) return fsencode(target) def opendir(self, inode, ctx): return inode def readdir(self, inode, off): path = self._inode_to_path(inode) log.debug('reading %s', path) entries = [] for name in os.listdir(path): attr = self._getattr(path=os.path.join(path, name)) entries.append((attr.st_ino, name, attr)) log.debug('read %d entries, starting at %d', len(entries), off) # This is not fully posix compatible. If there are hardlinks # (two names with the same inode), we don't have a unique # offset to start in between them. Note that we cannot simply # count entries, because then we would skip over entries # (or return them more than once) if the number of directory # entries changes between two calls to readdir(). for (ino, name, attr) in sorted(entries): if ino <= off: continue yield (fsencode(name), attr, ino) def unlink(self, inode_p, name, ctx): name = fsdecode(name) parent = self._inode_to_path(inode_p) path = os.path.join(parent, name) try: inode = os.lstat(path).st_ino os.unlink(path) except OSError as exc: raise FUSEError(exc.errno) if inode in self._lookup_cnt: self._forget_path(inode, path) def rmdir(self, inode_p, name, ctx): name = fsdecode(name) parent = self._inode_to_path(inode_p) path = os.path.join(parent, name) try: inode = os.lstat(path).st_ino os.rmdir(path) except OSError as exc: raise FUSEError(exc.errno) if inode in self._lookup_cnt: self._forget_path(inode, path) def _forget_path(self, inode, path): log.debug('forget %s for %d', path, inode) val = self._inode_path_map[inode] if isinstance(val, set): val.remove(path) if len(val) == 1: self._inode_path_map[inode] = next(iter(val)) else: del self._inode_path_map[inode] def symlink(self, inode_p, name, target, ctx): name = fsdecode(name) target = fsdecode(target) parent = self._inode_to_path(inode_p) path = os.path.join(parent, name) try: os.symlink(target, path) except OSError as exc: raise FUSEError(exc.errno) stat = os.lstat(path) self._add_path(stat.st_ino, path) return self.getattr(stat.st_ino) def rename(self, inode_p_old, name_old, inode_p_new, name_new, ctx): name_old = fsdecode(name_old) name_new = fsdecode(name_new) parent_old = self._inode_to_path(inode_p_old) parent_new = self._inode_to_path(inode_p_new) path_old = os.path.join(parent_old, name_old) path_new = os.path.join(parent_new, name_new) try: os.rename(path_old, path_new) inode = os.lstat(path_new).st_ino except OSError as exc: raise FUSEError(exc.errno) if inode not in self._lookup_cnt: return val = self._inode_path_map[inode] if isinstance(val, set): assert len(val) > 1 set.add(path_new) set.remove(path_old) else: assert val == path_old self._inode_path_map[inode] = path_new def link(self, inode, new_inode_p, new_name, ctx): new_name = fsdecode(new_name) parent = self._inode_to_path(new_inode_p) path = os.path.join(parent, new_name) try: os.link(self._inode_to_path(inode), path, follow_symlinks=False) except OSError as exc: raise FUSEError(exc.errno) self._add_path(inode, path) return self.getattr(inode) def setattr(self, inode, attr, fields, fh, ctx): # We use the f* functions if possible so that we can handle # a setattr() call for an inode without associated directory # handle. if fh is None: path_or_fh = self._inode_to_path(inode) truncate = os.truncate chmod = os.chmod chown = os.chown stat = os.lstat else: path_or_fh = fh truncate = os.ftruncate chmod = os.fchmod chown = os.fchown stat = os.fstat try: if fields.update_size: truncate(path_or_fh, attr.st_size) if fields.update_mode: # Under Linux, chmod always resolves symlinks so we should # actually never get a setattr() request for a symbolic # link. assert not stat_m.S_ISLNK(attr.st_mode) chmod(path_or_fh, stat_m.S_IMODE(attr.st_mode)) if fields.update_uid: chown(path_or_fh, attr.st_uid, -1, follow_symlinks=False) if fields.update_gid: chown(path_or_fh, -1, attr.st_gid, follow_symlinks=False) if fields.update_atime and fields.update_mtime: # utime accepts both paths and file descriptiors os.utime(path_or_fh, None, follow_symlinks=False, ns=(attr.st_atime_ns, attr.st_mtime_ns)) elif fields.update_atime or fields.update_mtime: # We can only set both values, so we first need to retrieve the # one that we shouldn't be changing. oldstat = stat(path_or_fh) if not fields.update_atime: attr.st_atime_ns = oldstat.st_atime_ns else: attr.st_mtime_ns = oldstat.st_mtime_ns os.utime(path_or_fh, None, follow_symlinks=False, ns=(attr.st_atime_ns, attr.st_mtime_ns)) except OSError as exc: raise FUSEError(exc.errno) return self.getattr(inode) def mknod(self, inode_p, name, mode, rdev, ctx): path = os.path.join(self._inode_to_path(inode_p), fsdecode(name)) try: os.mknod(path, mode=(mode & ~ctx.umask), device=rdev) os.chown(path, ctx.uid, ctx.gid) except OSError as exc: raise FUSEError(exc.errno) attr = self._getattr(path=path) self._add_path(attr.st_ino, path) return attr def mkdir(self, inode_p, name, mode, ctx): path = os.path.join(self._inode_to_path(inode_p), fsdecode(name)) try: os.mkdir(path, mode=(mode & ~ctx.umask)) os.chown(path, ctx.uid, ctx.gid) except OSError as exc: raise FUSEError(exc.errno) attr = self._getattr(path=path) self._add_path(attr.st_ino, path) return attr def statfs(self, ctx): stat_ = llfuse.StatvfsData() try: statfs = os.statvfs(self._inode_path_map[llfuse.ROOT_INODE]) except OSError as exc: raise FUSEError(exc.errno) for attr in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', 'f_bavail', 'f_files', 'f_ffree', 'f_favail'): setattr(stat_, attr, getattr(statfs, attr)) return stat_ def open(self, inode, flags, ctx): if inode in self._inode_fd_map: fd = self._inode_fd_map[inode] self._fd_open_count[fd] += 1 return fd assert flags & os.O_CREAT == 0 try: fd = os.open(self._inode_to_path(inode), flags) except OSError as exc: raise FUSEError(exc.errno) self._inode_fd_map[inode] = fd self._fd_inode_map[fd] = inode self._fd_open_count[fd] = 1 return fd def create(self, inode_p, name, mode, flags, ctx): path = os.path.join(self._inode_to_path(inode_p), fsdecode(name)) try: fd = os.open(path, flags | os.O_CREAT | os.O_TRUNC) except OSError as exc: raise FUSEError(exc.errno) attr = self._getattr(fd=fd) self._add_path(attr.st_ino, path) self._inode_fd_map[attr.st_ino] = fd self._fd_inode_map[fd] = attr.st_ino self._fd_open_count[fd] = 1 return (fd, attr) def read(self, fd, offset, length): os.lseek(fd, offset, os.SEEK_SET) return os.read(fd, length) def write(self, fd, offset, buf): os.lseek(fd, offset, os.SEEK_SET) return os.write(fd, buf) def release(self, fd): if self._fd_open_count[fd] > 1: self._fd_open_count[fd] -= 1 return del self._fd_open_count[fd] inode = self._fd_inode_map[fd] del self._inode_fd_map[inode] del self._fd_inode_map[fd] try: os.close(fd) except OSError as exc: raise FUSEError(exc.errno) def init_logging(debug=False): formatter = logging.Formatter('%(asctime)s.%(msecs)03d %(threadName)s: ' '[%(name)s] %(message)s', datefmt="%Y-%m-%d %H:%M:%S") handler = logging.StreamHandler() handler.setFormatter(formatter) root_logger = logging.getLogger() if debug: handler.setLevel(logging.DEBUG) root_logger.setLevel(logging.DEBUG) else: handler.setLevel(logging.INFO) root_logger.setLevel(logging.INFO) root_logger.addHandler(handler) def parse_args(args): '''Parse command line''' parser = ArgumentParser() parser.add_argument('source', type=str, help='Directory tree to mirror') parser.add_argument('mountpoint', type=str, help='Where to mount the file system') parser.add_argument('--single', action='store_true', default=False, help='Run single threaded') parser.add_argument('--debug', action='store_true', default=False, help='Enable debugging output') parser.add_argument('--debug-fuse', action='store_true', default=False, help='Enable FUSE debugging output') return parser.parse_args(args) def main(): options = parse_args(sys.argv[1:]) init_logging(options.debug) operations = Operations(options.source) log.debug('Mounting...') fuse_options = set(llfuse.default_options) fuse_options.add('fsname=passthroughfs') fuse_options.add('default_permissions') if options.debug_fuse: fuse_options.add('debug') llfuse.init(operations, options.mountpoint, fuse_options) try: log.debug('Entering main loop..') if options.single: llfuse.main(workers=1) else: llfuse.main() except: llfuse.close(unmount=False) raise log.debug('Unmounting..') llfuse.close() if __name__ == '__main__': main() llfuse-1.3.3/setup.py0000775000175000017500000002326313257660626016234 0ustar nikrationikratio00000000000000#!/usr/bin/env python #-*- coding: us-ascii -*- ''' setup.py Installation script for Python-LLFUSE. Copyright (c) 2010 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' from __future__ import division, print_function, absolute_import import sys import os import subprocess import warnings import re # Disable Cython support in setuptools. It fails under some conditions # (http://trac.cython.org/ticket/859), and we have our own build_cython command # anyway. try: import Cython.Distutils.build_ext except ImportError: pass else: # We can't delete Cython.Distutils.build_ext directly, # because the build_ext class (that is imported from # the build_ext module in __init__.py) shadows the # build_ext module. module = sys.modules['Cython.Distutils.build_ext'] del module.build_ext try: import setuptools except ImportError: raise SystemExit('Setuptools package not found. Please install from ' 'https://pypi.python.org/pypi/setuptools') from setuptools import Extension from distutils.version import LooseVersion # Add util to load path basedir = os.path.abspath(os.path.dirname(sys.argv[0])) sys.path.insert(0, os.path.join(basedir, 'util')) # When running from HG repo, enable all warnings DEVELOPER_MODE = os.path.exists(os.path.join(basedir, 'MANIFEST.in')) if DEVELOPER_MODE: print('found MANIFEST.in, running in developer mode') warnings.resetwarnings() # We can't use `error`, because e.g. Sphinx triggers a # DeprecationWarning. warnings.simplefilter('default') # Add src to load path, important for Sphinx autodoc # to work properly sys.path.insert(0, os.path.join(basedir, 'src')) LLFUSE_VERSION = '1.3.3' def main(): try: from sphinx.application import Sphinx #pylint: disable-msg=W0612 except ImportError: pass else: fix_docutils() with open(os.path.join(basedir, 'README.rst'), 'r') as fh: long_desc = fh.read() compile_args = pkg_config('fuse', cflags=True, ldflags=False, min_ver='2.8.0') compile_args += ['-DFUSE_USE_VERSION=29', '-Wall', '-Wextra', '-Wconversion', '-Wsign-compare', '-DLLFUSE_VERSION="%s"' % LLFUSE_VERSION] # We may have unused functions if we compile for older FUSE versions compile_args.append('-Wno-unused-function') # Nothing wrong with that if you know what you are doing # (which Cython does) compile_args.append('-Wno-implicit-fallthrough') # Due to platform specific conditions, these are unavoidable compile_args.append('-Wno-unused-parameter') # Value-changing conversions should always be explicit. compile_args.append('-Werror=conversion') # Note that (i > -1) is false if i is unsigned (-1 will be converted to # a large positive value). We certainly don't want to do this by # accident. compile_args.append('-Werror=sign-compare') # Enable all fatal warnings only when compiling from Mercurial tip. # (otherwise we break forward compatibility because compilation with newer # compiler may fail if additional warnings are added) if DEVELOPER_MODE: compile_args.append('-Werror') compile_args.append('-Wfatal-errors') # Unreachable code is expected because we need to support multiple # platforms and architectures. compile_args.append('-Wno-error=unreachable-code') # http://bugs.python.org/issue7576 if sys.version_info[0] == 3 and sys.version_info[1] < 2: compile_args.append('-Wno-error=missing-field-initializers') # http://bugs.python.org/issue969718 if sys.version_info[0] == 2: compile_args.append('-fno-strict-aliasing') link_args = pkg_config('fuse', cflags=False, ldflags=True, min_ver='2.8.0') link_args.append('-lpthread') c_sources = ['src/llfuse.c', 'src/lock.c'] if os.uname()[0] in ('Linux', 'GNU/kFreeBSD'): link_args.append('-lrt') elif os.uname()[0] == 'Darwin': c_sources.append('src/darwin_compat.c') install_requires = [] if sys.version_info[0] == 2: install_requires.append('contextlib2') setuptools.setup( name='llfuse', zip_safe=True, version=LLFUSE_VERSION, description='Python bindings for the low-level FUSE API', long_description=long_desc, author='Nikolaus Rath', author_email='Nikolaus@rath.org', url='https://bitbucket.org/nikratio/python-llfuse/', download_url='https://bitbucket.org/nikratio/python-llfuse/downloads', license='LGPL', classifiers=['Development Status :: 4 - Beta', 'Intended Audience :: Developers', 'Programming Language :: Python', 'Topic :: Software Development :: Libraries :: Python Modules', 'Topic :: System :: Filesystems', 'License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL)', 'Operating System :: POSIX :: Linux', 'Operating System :: MacOS :: MacOS X', 'Operating System :: POSIX :: BSD :: FreeBSD'], platforms=[ 'Linux', 'FreeBSD', 'OS X' ], keywords=['FUSE', 'python' ], package_dir={'': 'src'}, packages=setuptools.find_packages('src'), provides=['llfuse'], ext_modules=[Extension('llfuse', c_sources, extra_compile_args=compile_args, extra_link_args=link_args)], cmdclass={'upload_docs': upload_docs, 'build_cython': build_cython }, command_options={ 'build_sphinx': { 'version': ('setup.py', LLFUSE_VERSION), 'release': ('setup.py', LLFUSE_VERSION), }}, install_requires=install_requires, ) def pkg_config(pkg, cflags=True, ldflags=False, min_ver=None): '''Frontend to ``pkg-config``''' if min_ver: cmd = ['pkg-config', pkg, '--atleast-version', min_ver ] if subprocess.call(cmd) != 0: cmd = ['pkg-config', '--modversion', pkg ] proc = subprocess.Popen(cmd, stdout=subprocess.PIPE) version = proc.communicate()[0].strip() if not version: raise SystemExit() # pkg-config generates error message already else: raise SystemExit('%s version too old (found: %s, required: %s)' % (pkg, version, min_ver)) cmd = ['pkg-config', pkg ] if cflags: cmd.append('--cflags') if ldflags: cmd.append('--libs') proc = subprocess.Popen(cmd, stdout=subprocess.PIPE) cflags = proc.stdout.readline().rstrip() proc.stdout.close() if proc.wait() != 0: raise SystemExit() # pkg-config generates error message already return cflags.decode('us-ascii').split() class upload_docs(setuptools.Command): user_options = [] boolean_options = [] description = "Upload documentation" def initialize_options(self): pass def finalize_options(self): pass def run(self): subprocess.check_call(['rsync', '-aHv', '--del', os.path.join(basedir, 'doc', 'html') + '/', 'ebox.rath.org:/srv/www.rath.org/llfuse-docs/']) class build_cython(setuptools.Command): user_options = [] boolean_options = [] description = "Compile .pyx to .c" def initialize_options(self): pass def finalize_options(self): self.extensions = self.distribution.ext_modules def run(self): try: version = subprocess.check_output(['cython', '--version'], universal_newlines=True, stderr=subprocess.STDOUT) except OSError: raise SystemExit('Cython needs to be installed for this command') hit = re.match('^Cython version (.+)$', version) if not hit or LooseVersion(hit.group(1)) < "0.24": raise SystemExit('Need Cython 0.24 or newer, found ' + version) cmd = ['cython', '-Wextra', '--force', '-3', '--fast-fail', '--directive', 'embedsignature=True', '--include-dir', os.path.join(basedir, 'Include'), '--verbose' ] if DEVELOPER_MODE: cmd.append('-Werror') # Work around http://trac.cython.org/cython_trac/ticket/714 cmd += ['-X', 'warn.maybe_uninitialized=False' ] for extension in self.extensions: for file_ in extension.sources: (file_, ext) = os.path.splitext(file_) path = os.path.join(basedir, file_) if ext != '.c': continue if os.path.exists(path + '.pyx'): if subprocess.call(cmd + [path + '.pyx']) != 0: raise SystemExit('Cython compilation failed') def fix_docutils(): '''Work around https://bitbucket.org/birkenfeld/sphinx/issue/1154/''' import docutils.parsers from docutils.parsers import rst old_getclass = docutils.parsers.get_parser_class # Check if bug is there try: old_getclass('rst') except AttributeError: pass else: return def get_parser_class(parser_name): """Return the Parser class from the `parser_name` module.""" if parser_name in ('rst', 'restructuredtext'): return rst.Parser else: return old_getclass(parser_name) docutils.parsers.get_parser_class = get_parser_class assert docutils.parsers.get_parser_class('rst') is rst.Parser if __name__ == '__main__': main() llfuse-1.3.3/src/0000775000175000017500000000000013257663654015304 5ustar nikrationikratio00000000000000llfuse-1.3.3/src/lock.c0000664000175000017500000000746512653313107016374 0ustar nikrationikratio00000000000000/* lock.c This file provides the plain C components for the global lock. Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. */ #include "lock.h" #define TRUE (1==1) #define FALSE (0==1) #include #include #include #ifdef __MACH__ #include #endif #define GIGA ((long)1e9) // Who was the last to acquire the lock static pthread_t lock_owner; // Is the lock currently taken static int lock_taken = FALSE; /* This variable indicates how many threads are currently waiting for * the lock. */ static int lock_wanted = 0; /* Mutex for protecting access to lock_wanted, lock_owner and * lock_taken */ static pthread_mutex_t mutex; /* Condition even to notify when the lock becomes available */ static pthread_cond_t cond; void init_lock(void) { pthread_cond_init(&cond, NULL); pthread_mutex_init(&mutex, NULL); } int acquire(double timeout) { int ret; struct timespec abstime; #ifdef __MACH__ struct timeval tv; #endif pthread_t me = pthread_self(); if(timeout != 0) { #ifdef __MACH__ ret = gettimeofday(&tv, NULL); if(ret != 0) return ret; abstime.tv_sec = tv.tv_sec; abstime.tv_nsec = tv.tv_usec * 1000; #else ret = clock_gettime(CLOCK_REALTIME, &abstime); if(ret != 0) return ret; #endif abstime.tv_nsec += (long)(timeout - (int) timeout) * GIGA; if(abstime.tv_nsec >= GIGA) { abstime.tv_sec += abstime.tv_nsec / GIGA; abstime.tv_nsec = abstime.tv_nsec % GIGA; } abstime.tv_sec += (int) timeout; } ret = pthread_mutex_lock(&mutex); if(ret != 0) return ret; if(lock_taken) { if(pthread_equal(lock_owner, me)) { pthread_mutex_unlock(&mutex); return EDEADLK; } lock_wanted++; /* We need while here even though pthread_cond_signal wakes * only one thread: * http://stackoverflow.com/questions/8378789/forcing-a-thread-context-switch * http://en.wikipedia.org/wiki/Spurious_wakeup */ if(timeout == 0) while(lock_taken) pthread_cond_wait(&cond, &mutex); else while(lock_taken) { ret = pthread_cond_timedwait(&cond, &mutex, &abstime); if(ret == ETIMEDOUT) { lock_wanted--; pthread_mutex_unlock(&mutex); return ret; } } lock_wanted--; } lock_taken = TRUE; lock_owner = me; return pthread_mutex_unlock(&mutex); } int release(void) { int ret; if(!lock_taken) return EPERM; if(!pthread_equal(lock_owner, pthread_self())) return EPERM; ret = pthread_mutex_lock(&mutex); if(ret != 0) return ret; lock_taken = FALSE; if(lock_wanted > 0) { pthread_cond_signal(&cond); } return pthread_mutex_unlock(&mutex); } int c_yield(int count) { int ret; int i; pthread_t me = pthread_self(); if(!lock_taken || !pthread_equal(lock_owner, me)) return EPERM; ret = pthread_mutex_lock(&mutex); if(ret != 0) return ret; for(i=0; i < count; i++) { if(lock_wanted == 0) break; lock_taken = FALSE; lock_wanted++; pthread_cond_signal(&cond); // See acquire() for why 'while' is required do { pthread_cond_wait(&cond, &mutex); } while(lock_taken); lock_wanted--; if(lock_taken) { pthread_mutex_unlock(&mutex); return EPROTO; } if(pthread_equal(lock_owner, me)) { pthread_mutex_unlock(&mutex); return ENOMSG; } lock_taken = TRUE; lock_owner = me; } return pthread_mutex_unlock(&mutex); } llfuse-1.3.3/src/darwin_compat.c0000664000175000017500000001400112653314441020255 0ustar nikrationikratio00000000000000/* * Copyright (c) 2006-2008 Amit Singh/Google Inc. * Copyright (c) 2012 Anatol Pomozov * Copyright (c) 2011-2013 Benjamin Fleischer */ #include "darwin_compat.h" #include #include #include /* * Semaphore implementation based on: * * Copyright (C) 2000,02 Free Software Foundation, Inc. * This file is part of the GNU C Library. * Written by Gal Le Mignot * * The GNU C Library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public License as * published by the Free Software Foundation; either version 2 of the * License, or (at your option) any later version. * * The GNU C Library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public * License along with the GNU C Library; see the file COPYING.LIB. If not, * write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ /* Semaphores */ #define __SEM_ID_NONE ((int)0x0) #define __SEM_ID_LOCAL ((int)0xcafef00d) /* http://www.opengroup.org/onlinepubs/007908799/xsh/sem_init.html */ int darwin_sem_init(darwin_sem_t *sem, int pshared, unsigned int value) { if (pshared) { errno = ENOSYS; return -1; } sem->id = __SEM_ID_NONE; if (pthread_cond_init(&sem->__data.local.count_cond, NULL)) { goto cond_init_fail; } if (pthread_mutex_init(&sem->__data.local.count_lock, NULL)) { goto mutex_init_fail; } sem->__data.local.count = value; sem->id = __SEM_ID_LOCAL; return 0; mutex_init_fail: pthread_cond_destroy(&sem->__data.local.count_cond); cond_init_fail: return -1; } /* http://www.opengroup.org/onlinepubs/007908799/xsh/sem_destroy.html */ int darwin_sem_destroy(darwin_sem_t *sem) { int res = 0; pthread_mutex_lock(&sem->__data.local.count_lock); sem->id = __SEM_ID_NONE; pthread_cond_broadcast(&sem->__data.local.count_cond); if (pthread_cond_destroy(&sem->__data.local.count_cond)) { res = -1; } pthread_mutex_unlock(&sem->__data.local.count_lock); if (pthread_mutex_destroy(&sem->__data.local.count_lock)) { res = -1; } return res; } int darwin_sem_getvalue(darwin_sem_t *sem, unsigned int *sval) { int res = 0; pthread_mutex_lock(&sem->__data.local.count_lock); if (sem->id != __SEM_ID_LOCAL) { res = -1; errno = EINVAL; } else { *sval = sem->__data.local.count; } pthread_mutex_unlock(&sem->__data.local.count_lock); return res; } /* http://www.opengroup.org/onlinepubs/007908799/xsh/sem_post.html */ int darwin_sem_post(darwin_sem_t *sem) { int res = 0; pthread_mutex_lock(&sem->__data.local.count_lock); if (sem->id != __SEM_ID_LOCAL) { res = -1; errno = EINVAL; } else if (sem->__data.local.count < DARWIN_SEM_VALUE_MAX) { sem->__data.local.count++; if (sem->__data.local.count == 1) { pthread_cond_signal(&sem->__data.local.count_cond); } } else { errno = ERANGE; res = -1; } pthread_mutex_unlock(&sem->__data.local.count_lock); return res; } /* http://www.opengroup.org/onlinepubs/009695399/functions/sem_timedwait.html */ int darwin_sem_timedwait(darwin_sem_t *sem, const struct timespec *abs_timeout) { int res = 0; if (abs_timeout && (abs_timeout->tv_nsec < 0 || abs_timeout->tv_nsec >= 1000000000)) { errno = EINVAL; return -1; } pthread_cleanup_push((void(*)(void*))&pthread_mutex_unlock, &sem->__data.local.count_lock); pthread_mutex_lock(&sem->__data.local.count_lock); if (sem->id != __SEM_ID_LOCAL) { errno = EINVAL; res = -1; } else { if (!sem->__data.local.count) { res = pthread_cond_timedwait(&sem->__data.local.count_cond, &sem->__data.local.count_lock, abs_timeout); } if (res) { assert(res == ETIMEDOUT); res = -1; errno = ETIMEDOUT; } else if (sem->id != __SEM_ID_LOCAL) { res = -1; errno = EINVAL; } else { sem->__data.local.count--; } } pthread_cleanup_pop(1); return res; } /* http://www.opengroup.org/onlinepubs/007908799/xsh/sem_trywait.html */ int darwin_sem_trywait(darwin_sem_t *sem) { int res = 0; pthread_mutex_lock(&sem->__data.local.count_lock); if (sem->id != __SEM_ID_LOCAL) { res = -1; errno = EINVAL; } else if (sem->__data.local.count) { sem->__data.local.count--; } else { res = -1; errno = EAGAIN; } pthread_mutex_unlock (&sem->__data.local.count_lock); return res; } /* http://www.opengroup.org/onlinepubs/007908799/xsh/sem_wait.html */ int darwin_sem_wait(darwin_sem_t *sem) { /* Must be volatile or will be clobbered by longjmp */ volatile int res = 0; pthread_cleanup_push((void(*)(void*))&pthread_mutex_unlock, &sem->__data.local.count_lock); pthread_mutex_lock(&sem->__data.local.count_lock); if (sem->id != __SEM_ID_LOCAL) { errno = EINVAL; res = -1; } else { if (!sem->__data.local.count) { pthread_cond_wait(&sem->__data.local.count_cond, &sem->__data.local.count_lock); if (!sem->__data.local.count) { /* spurious wakeup, assume it is an interruption */ res = -1; errno = EINTR; goto out; } } if (sem->id != __SEM_ID_LOCAL) { res = -1; errno = EINVAL; } else { sem->__data.local.count--; } } out: pthread_cleanup_pop(1); return res; } llfuse-1.3.3/src/llfuse.egg-info/0000775000175000017500000000000013257663654020270 5ustar nikrationikratio00000000000000llfuse-1.3.3/src/llfuse.egg-info/top_level.txt0000664000175000017500000000000713257663654023017 0ustar nikrationikratio00000000000000llfuse llfuse-1.3.3/src/llfuse.egg-info/PKG-INFO0000664000175000017500000000733213257663654021372 0ustar nikrationikratio00000000000000Metadata-Version: 1.1 Name: llfuse Version: 1.3.3 Summary: Python bindings for the low-level FUSE API Home-page: https://bitbucket.org/nikratio/python-llfuse/ Author: Nikolaus Rath Author-email: Nikolaus@rath.org License: LGPL Download-URL: https://bitbucket.org/nikratio/python-llfuse/downloads Description: .. NOTE: We cannot use sophisticated ReST syntax (like e.g. :file:`foo`) here because this isn't rendered correctly by PyPi and/or BitBucket. The Python-LLFUSE Module ======================== .. start-intro Python-LLFUSE is a set of Python bindings for the low level FUSE_ API. It requires at least FUSE 2.8.0 and supports both Python 2.x and 3.x. Like FUSE itself, Python-LLFUSE is developed for Linux systems. However, we try to maintain compatibility with OS-X, FreeBSD and NetBSD as well (but due to lack of pre-release testers we can't guarantee that every Python-LLFUSE release will run on these platforms - please report any bugs and we will try to fix them). Python-LLFUSE releases can be downloaded from PyPi_. The documentation can be `read online`__ and is also included in the ``doc/html`` directory of the Python-LLFUSE tarball. Getting Help ------------ Please report any bugs on the `issue tracker`_. For discussion and questions, please use the general `FUSE mailing list`_. A searchable `mailing list archive`_ is kindly provided by Gmane_. Development Status ------------------ The Python-LLFUSE API is not yet stable and may change from one release to the other. Starting with version 0.42, Python-LLFUSE uses semantic versioning. This means changes in the API will be reflected in an increase of the major version number, i.e. the next backwards-incompatible version will be 1.0. Projects designed for e.g. version 0.42.1 of Python-LLFUSE are thus recommended to declare a dependency on ``llfuse >= 0.42.1, < 1.0``. Contributing ------------ The Python-LLFUSE source code is available both on GitHub_ and BitBucket_. Professional Support -------------------- Professional support is offered via `Rath Consulting`_. .. __: http://www.rath.org/llfuse-docs/ .. _FUSE: http://github.com/libfuse/libfuse .. _FUSE mailing list: https://lists.sourceforge.net/lists/listinfo/fuse-devel .. _issue tracker: https://bitbucket.org/nikratio/python-llfuse/issues .. _mailing list archive: http://dir.gmane.org/gmane.comp.file-systems.fuse.devel .. _Gmane: http://www.gmane.org/ .. _PyPi: https://pypi.python.org/pypi/llfuse/ .. _BitBucket: https://bitbucket.org/nikratio/python-llfuse/ .. _GitHub: https://github.com/python-llfuse/python-llfuse .. _`Rath Consulting`: http://www.rath-consulting.biz/ Keywords: FUSE,python Platform: Linux Platform: FreeBSD Platform: OS X Classifier: Development Status :: 4 - Beta Classifier: Intended Audience :: Developers Classifier: Programming Language :: Python Classifier: Topic :: Software Development :: Libraries :: Python Modules Classifier: Topic :: System :: Filesystems Classifier: License :: OSI Approved :: GNU Library or Lesser General Public License (LGPL) Classifier: Operating System :: POSIX :: Linux Classifier: Operating System :: MacOS :: MacOS X Classifier: Operating System :: POSIX :: BSD :: FreeBSD Provides: llfuse llfuse-1.3.3/src/llfuse.egg-info/SOURCES.txt0000664000175000017500000000467413257663654022167 0ustar nikrationikratio00000000000000Changes.rst LICENSE README.rst setup.cfg setup.py Include/fuse_common.pxd Include/fuse_lowlevel.pxd Include/fuse_opt.pxd Include/pthread.pxd Include/libc/__init__.py Include/libc/dirent.pxd Include/libc/sys/__init__.py Include/libc/sys/statvfs.pxd doc/html/.buildinfo doc/html/about.html doc/html/changes.html doc/html/data.html doc/html/example.html doc/html/fuse_api.html doc/html/general.html doc/html/genindex.html doc/html/gotchas.html doc/html/index.html doc/html/install.html doc/html/lock.html doc/html/objects.inv doc/html/operations.html doc/html/search.html doc/html/searchindex.js doc/html/util.html doc/html/_sources/about.txt doc/html/_sources/changes.txt doc/html/_sources/data.txt doc/html/_sources/example.txt doc/html/_sources/fuse_api.txt doc/html/_sources/general.txt doc/html/_sources/gotchas.txt doc/html/_sources/index.txt doc/html/_sources/install.txt doc/html/_sources/lock.txt doc/html/_sources/operations.txt doc/html/_sources/util.txt doc/html/_static/ajax-loader.gif doc/html/_static/basic.css doc/html/_static/classic.css doc/html/_static/comment-bright.png doc/html/_static/comment-close.png doc/html/_static/comment.png doc/html/_static/default.css doc/html/_static/doctools.js doc/html/_static/down-pressed.png doc/html/_static/down.png doc/html/_static/file.png doc/html/_static/jquery.js doc/html/_static/minus.png doc/html/_static/plus.png doc/html/_static/pygments.css doc/html/_static/searchtools.js doc/html/_static/sidebar.js doc/html/_static/underscore.js doc/html/_static/up-pressed.png doc/html/_static/up.png doc/html/_static/websupport.js examples/lltest.py examples/passthroughfs.py examples/tmpfs.py rst/about.rst rst/changes.rst rst/conf.py rst/data.rst rst/example.rst rst/fuse_api.rst rst/general.rst rst/gotchas.rst rst/index.rst rst/install.rst rst/lock.rst rst/operations.rst rst/util.rst rst/_static/.placeholder rst/_templates/localtoc.html src/darwin_compat.c src/darwin_compat.h src/fuse_api.pxi src/gettime.h src/handlers.pxi src/llfuse.c src/llfuse.h src/llfuse.pyx src/lock.c src/lock.h src/macros.c src/misc.pxi src/operations.pxi src/xattr.h src/llfuse.egg-info/PKG-INFO src/llfuse.egg-info/SOURCES.txt src/llfuse.egg-info/dependency_links.txt src/llfuse.egg-info/requires.txt src/llfuse.egg-info/top_level.txt src/llfuse.egg-info/zip-safe test/conftest.py test/pytest.ini test/pytest_checklogs.py test/test_api.py test/test_examples.py test/test_fs.py test/travis-install.sh test/travis-test.sh test/util.py util/sphinx_cython.pyllfuse-1.3.3/src/llfuse.egg-info/requires.txt0000664000175000017500000000001413257663654022663 0ustar nikrationikratio00000000000000contextlib2 llfuse-1.3.3/src/llfuse.egg-info/zip-safe0000664000175000017500000000000112653305611021701 0ustar nikrationikratio00000000000000 llfuse-1.3.3/src/llfuse.egg-info/dependency_links.txt0000664000175000017500000000000113257663654024336 0ustar nikrationikratio00000000000000 llfuse-1.3.3/src/darwin_compat.h0000644000175000017500000000254012653314441020265 0ustar nikrationikratio00000000000000/* * Copyright (c) 2006-2008 Amit Singh/Google Inc. * Copyright (c) 2011-2013 Benjamin Fleischer */ #ifndef _DARWIN_COMPAT_ #define _DARWIN_COMPAT_ #include /* Semaphores */ typedef struct darwin_sem { int id; union { struct { unsigned int count; pthread_mutex_t count_lock; pthread_cond_t count_cond; } local; } __data; } darwin_sem_t; #define DARWIN_SEM_VALUE_MAX ((int32_t)32767) int darwin_sem_init(darwin_sem_t *sem, int pshared, unsigned int value); int darwin_sem_destroy(darwin_sem_t *sem); int darwin_sem_getvalue(darwin_sem_t *sem, unsigned int *value); int darwin_sem_post(darwin_sem_t *sem); int darwin_sem_timedwait(darwin_sem_t *sem, const struct timespec *abs_timeout); int darwin_sem_trywait(darwin_sem_t *sem); int darwin_sem_wait(darwin_sem_t *sem); /* Caller must not include */ typedef darwin_sem_t sem_t; #define sem_init(s, p, v) darwin_sem_init(s, p, v) #define sem_destroy(s) darwin_sem_destroy(s) #define sem_getvalue(s, v) darwin_sem_getvalue(s, v) #define sem_post(s) darwin_sem_post(s) #define sem_timedwait(s, t) darwin_sem_timedwait(s, t) #define sem_trywait(s) darwin_sem_trywait(s) #define sem_wait(s) darwin_sem_wait(s) #define SEM_VALUE_MAX DARWIN_SEM_VALUE_MAX #endif /* _DARWIN_COMPAT_ */ llfuse-1.3.3/src/operations.pxi0000644000175000017500000004702413004541326020173 0ustar nikrationikratio00000000000000# -*- coding: utf-8 -*- ''' operations.pxi Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' class Operations(object): ''' This class defines the general and request handler methods that an Python-LLFUSE file system may implement. If a particular request handler has not been implemented, it must raise `FUSEError` with an errorcode of `errno.ENOSYS`. Further requests of this type will then be handled directly by the FUSE kernel module without calling the handler again. The only exception that request handlers are allowed to raise is `FUSEError`. This will cause the specified errno to be returned by the syscall that is being handled. It is recommended that file systems are derived from this class and only overwrite the handlers that they actually implement. (The methods defined in this class all just raise ``FUSEError(ENOSYS)`` or do nothing). ''' def init(self): '''Initialize operations This method will be called just before the file system starts handling requests. It must not raise any exceptions (not even `FUSEError`), since it is not handling a particular client request. ''' pass def destroy(self): '''Clean up operations. This method will be called when `llfuse.close` has been called and the file system is about to be unmounted. This method must not raise any exceptions (not even `FUSEError`), since it is not handling a particular client request. ''' pass def lookup(self, parent_inode, name, ctx): '''Look up a directory entry by name and get its attributes. This method should return an `EntryAttributes` instance for the directory entry *name* in the directory with inode *parent_inode*. If there is no such entry, the method should either return an `EntryAttributes` instance with zero ``st_ino`` value (in which case the negative lookup will be cached as specified by ``entry_timeout``), or it should raise `FUSEError` with an errno of `errno.ENOENT` (in this case the negative result will not be cached). *ctx* will be a `RequestContext` instance. The file system must be able to handle lookups for :file:`.` and :file:`..`, no matter if these entries are returned by `readdir` or not. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) def forget(self, inode_list): '''Decrease lookup counts for inodes in *inode_list* *inode_list* is a list of ``(inode, nlookup)`` tuples. This method should reduce the lookup count for each *inode* by *nlookup*. If the lookup count reaches zero, the inode is currently not known to the kernel. In this case, the file system will typically check if there are still directory entries referring to this inode and, if not, remove the inode. If the file system is unmounted, it may not have received `forget` calls to bring all lookup counts to zero. The `destroy` method should be used to clean up inodes that at that point still have non-zero lookup count (e.g. by calling `forget` with the current lookup count for every such inode). This method must not raise any exceptions (not even `FUSEError`), since it is not handling a particular client request. ''' pass def getattr(self, inode, ctx): '''Get attributes for *inode* *ctx* will be a `RequestContext` instance. This method should return an `EntryAttributes` instance with the attributes of *inode*. The `~EntryAttributes.entry_timeout` attribute is ignored in this context. ''' raise FUSEError(errno.ENOSYS) def setattr(self, inode, attr, fields, fh, ctx): '''Change attributes of *inode* *fields* will be an `SetattrFields` instance that specifies which attributes are to be updated. *attr* will be an `EntryAttributes` instance for *inode* that contains the new values for changed attributes, and undefined values for all other attributes. Most file systems will additionally set the `~EntryAttributes.st_ctime_ns` attribute to the current time (to indicate that the inode metadata was changed). If the syscall that is being processed received a file descriptor argument (like e.g. :manpage:`ftruncate(2)` or :manpage:`fchmod(2)`), *fh* will be the file handle returned by the corresponding call to the `open` handler. If the syscall was path based (like e.g. :manpage:`truncate(2)` or :manpage:`chmod(2)`), *fh* will be `None`. *ctx* will be a `RequestContext` instance. The method should return an `EntryAttributes` instance (containing both the changed and unchanged values). ''' raise FUSEError(errno.ENOSYS) def readlink(self, inode, ctx): '''Return target of symbolic link *inode*. *ctx* will be a `RequestContext` instance. ''' raise FUSEError(errno.ENOSYS) def mknod(self, parent_inode, name, mode, rdev, ctx): '''Create (possibly special) file This method must create a (special or regular) file *name* in the directory with inode *parent_inode*. Whether the file is special or regular is determined by its *mode*. If the file is neither a block nor character device, *rdev* can be ignored. *ctx* will be a `RequestContext` instance. The method must return an `EntryAttributes` instance with the attributes of the newly created directory entry. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) def mkdir(self, parent_inode, name, mode, ctx): '''Create a directory This method must create a new directory *name* with mode *mode* in the directory with inode *parent_inode*. *ctx* will be a `RequestContext` instance. This method must return an `EntryAttributes` instance with the attributes of the newly created directory entry. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) def unlink(self, parent_inode, name, ctx): '''Remove a (possibly special) file This method must remove the (special or regular) file *name* from the direcory with inode *parent_inode*. *ctx* will be a `RequestContext` instance. If the inode associated with *file* (i.e., not the *parent_inode*) has a non-zero lookup count, or if there are still other directory entries referring to this inode (due to hardlinks), the file system must remove only the directory entry (so that future calls to `readdir` for *parent_inode* will no longer include *name*, but e.g. calls to `getattr` for *file*'s inode still succeed). (Potential) removal of the associated inode with the file contents and metadata must be deferred to the `forget` method to be carried out when the lookup count reaches zero (and of course only if at that point there are no more directory entries associated with the inode either). ''' raise FUSEError(errno.ENOSYS) def rmdir(self, parent_inode, name, ctx): '''Remove directory *name* This method must remove the directory *name* from the direcory with inode *parent_inode*. *ctx* will be a `RequestContext` instance. If there are still entries in the directory, the method should raise ``FUSEError(errno.ENOTEMPTY)``. If the inode associated with *name* (i.e., not the *parent_inode*) has a non-zero lookup count, the file system must remove only the directory entry (so that future calls to `readdir` for *parent_inode* will no longer include *name*, but e.g. calls to `getattr` for *file*'s inode still succeed). Removal of the associated inode holding the directory contents and metadata must be deferred to the `forget` method to be carried out when the lookup count reaches zero. (Since hard links to directories are not allowed by POSIX, this method is not required to check if there are still other directory entries refering to the same inode. This conveniently avoids the ambigiouties associated with the ``.`` and ``..`` entries). ''' raise FUSEError(errno.ENOSYS) def symlink(self, parent_inode, name, target, ctx): '''Create a symbolic link This method must create a symbolink link named *name* in the directory with inode *parent_inode*, pointing to *target*. *ctx* will be a `RequestContext` instance. The method must return an `EntryAttributes` instance with the attributes of the newly created directory entry. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) def rename(self, parent_inode_old, name_old, parent_inode_new, name_new, ctx): '''Rename a directory entry. This method must rename *name_old* in the directory with inode *parent_inode_old* to *name_new* in the directory with inode *parent_inode_new*. If *name_new* already exists, it should be overwritten. *ctx* will be a `RequestContext` instance. Let the inode associated with *name_old* in *parent_inode_old* be *inode_moved*, and the inode associated with *name_new* in *parent_inode_new* (if it exists) be called *inode_deref*. If *inode_deref* exists and has a non-zero lookup count, or if there are other directory entries referring to *inode_deref*), the file system must update only the directory entry for *name_new* to point to *inode_moved* instead of *inode_deref*. (Potential) removal of *inode_deref* (containing the previous contents of *name_new*) must be deferred to the `forget` method to be carried out when the lookup count reaches zero (and of course only if at that point there are no more directory entries associated with *inode_deref* either). ''' raise FUSEError(errno.ENOSYS) def link(self, inode, new_parent_inode, new_name, ctx): '''Create directory entry *name* in *parent_inode* refering to *inode*. *ctx* will be a `RequestContext` instance. The method must return an `EntryAttributes` instance with the attributes of the newly created directory entry. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) def open(self, inode, flags, ctx): '''Open a inode *inode* with *flags*. *ctx* will be a `RequestContext` instance. *flags* will be a bitwise or of the open flags described in the :manpage:`open(2)` manpage and defined in the `os` module (with the exception of ``O_CREAT``, ``O_EXCL``, ``O_NOCTTY`` and ``O_TRUNC``) This method must return an integer file handle. The file handle will be passed to the `read`, `write`, `flush`, `fsync` and `release` methods to identify the open file. ''' raise FUSEError(errno.ENOSYS) def read(self, fh, off, size): '''Read *size* bytes from *fh* at position *off* *fh* will by an integer filehandle returned by a prior `open` or `create` call. This function should return exactly the number of bytes requested except on EOF or error, otherwise the rest of the data will be substituted with zeroes. ''' raise FUSEError(errno.ENOSYS) def write(self, fh, off, buf): '''Write *buf* into *fh* at *off* *fh* will by an integer filehandle returned by a prior `open` or `create` call. This method must returns the number of bytes written. However, uuless the file system has been mounted with the ``direct_io`` option, the file system *must* always write *all* the provided data (i.e., return ``len(buf)``). ''' raise FUSEError(errno.ENOSYS) def flush(self, fh): '''Handle close() syscall. *fh* will by an integer filehandle returned by a prior `open` or `create` call. This method is called whenever a file descriptor is closed. It may be called multiple times for the same open file (e.g. if the file handle has been duplicated). ''' raise FUSEError(errno.ENOSYS) def release(self, fh): '''Release open file This method will be called when the last file descriptor of *fh* has been closed, i.e. when the file is no longer opened by any client process. *fh* will by an integer filehandle returned by a prior `open` or `create` call. Once `release` has been called, no future requests for *fh* will be received (until the value is re-used in the return value of another `open` or `create` call). This method may return an error by raising `FUSEError`, but the error will be discarded because there is no corresponding client request. ''' raise FUSEError(errno.ENOSYS) def fsync(self, fh, datasync): '''Flush buffers for open file *fh* If *datasync* is true, only the file contents should be flushed (in contrast to the metadata about the file). *fh* will by an integer filehandle returned by a prior `open` or `create` call. ''' raise FUSEError(errno.ENOSYS) def opendir(self, inode, ctx): '''Open the directory with inode *inode* *ctx* will be a `RequestContext` instance. This method should return an integer file handle. The file handle will be passed to the `readdir`, `fsyncdir` and `releasedir` methods to identify the directory. ''' raise FUSEError(errno.ENOSYS) def readdir(self, fh, off): '''Read entries in open directory *fh*. This method should return an iterator over the contents of directory *fh* (as returned by a prior `opendir` call), starting at the entry identified by *off*. The iterator must yield tuples of the form :samp:`({name}, {attr}, {next_})`, where *attr* is an `EntryAttributes` instance and *next_* gives an offset that can be passed as *off* to start a successive `readdir` call at the right position. Iteration may be stopped as soon as enough elements have been retrieved. The method should be prepared for this case. If entries are added or removed during a `readdir` cycle, they may or may not be returned. However, they must not cause other entries to be skipped or returned more than once. :file:`.` and :file:`..` entries may be included but are not required. ''' raise FUSEError(errno.ENOSYS) def releasedir(self, fh): '''Release open directory This method will be called exactly once for each `opendir` call. After *fh* has been released, no further `readdir` requests will be received for it (until it is opened again with `opendir`). ''' raise FUSEError(errno.ENOSYS) def fsyncdir(self, fh, datasync): '''Flush buffers for open directory *fh* If *datasync* is true, only the directory contents should be flushed (in contrast to metadata about the directory itself). ''' raise FUSEError(errno.ENOSYS) def statfs(self, ctx): '''Get file system statistics *ctx* will be a `RequestContext` instance. The method must return an appropriately filled `StatvfsData` instance. ''' raise FUSEError(errno.ENOSYS) def stacktrace(self): '''Asynchronous debugging This method will be called when the ``fuse_stacktrace`` extended attribute is set on the mountpoint. It will be called without holding the global lock. The default implementation logs the current stack trace of every running Python thread. This can be quite useful to debug file system deadlocks. ''' import sys import traceback code = list() for threadId, frame in sys._current_frames().items(): code.append("\n# ThreadID: %s" % threadId) for filename, lineno, name, line in traceback.extract_stack(frame): code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) if line: code.append(" %s" % (line.strip())) log.error("\n".join(code)) def setxattr(self, inode, name, value, ctx): '''Set extended attribute *name* of *inode* to *value*. *ctx* will be a `RequestContext` instance. The attribute may or may not exist already. Both *name* and *value* will be of type `bytes`. *name* is guaranteed not to contain zero-bytes (``\\0``). ''' raise FUSEError(errno.ENOSYS) def getxattr(self, inode, name, ctx): '''Return extended attribute *name* of *inode* *ctx* will be a `RequestContext` instance. If the attribute does not exist, the method must raise `FUSEError` with an error code of `ENOATTR`. *name* will be of type `bytes`, but is guaranteed not to contain zero-bytes (``\\0``). ''' raise FUSEError(errno.ENOSYS) def listxattr(self, inode, ctx): '''Get list of extended attributes for *inode* *ctx* will be a `RequestContext` instance. This method must return an iterator over a sequence of `bytes` objects. The objects must not to include zero-bytes (``\\0``). ''' raise FUSEError(errno.ENOSYS) def removexattr(self, inode, name, ctx): '''Remove extended attribute *name* of *inode* *ctx* will be a `RequestContext` instance. If the attribute does not exist, the method must raise `FUSEError` with an error code of `ENOATTR`. *name* will be of type `bytes`, but is guaranteed not to contain zero-bytes (``\\0``). ''' raise FUSEError(errno.ENOSYS) def access(self, inode, mode, ctx): '''Check if requesting process has *mode* rights on *inode*. *ctx* will be a `RequestContext` instance. The method must return a boolean value. If the ``default_permissions`` mount option is given, this method is not called. When implementing this method, the `get_sup_groups` function may be useful. ''' raise FUSEError(errno.ENOSYS) def create(self, parent_inode, name, mode, flags, ctx): '''Create a file with permissions *mode* and open it with *flags* *ctx* will be a `RequestContext` instance. The method must return a tuple of the form *(fh, attr)*, where *fh* is a file handle like the one returned by `open` and *attr* is an `EntryAttributes` instance with the attributes of the newly created directory entry. (Successful) execution of this handler increases the lookup count for the returned inode by one. ''' raise FUSEError(errno.ENOSYS) llfuse-1.3.3/src/handlers.pxi0000644000175000017500000005626212667320620017622 0ustar nikrationikratio00000000000000''' handlers.pxi This file defines the FUSE request handlers. It is included by llfuse.pyx. Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: try: with lock: operations.init() except: handle_exc(NULL) cdef void fuse_destroy (void *userdata) with gil: global exc_info try: with lock: operations.destroy() except: if not exc_info: exc_info = sys.exc_info() else: log.exception('Exception after kill:') cdef void fuse_lookup (fuse_req_t req, fuse_ino_t parent, const_char *c_name) with gil: cdef EntryAttributes entry cdef int ret try: ctx = get_request_context(req) name = PyBytes_FromString(c_name) with lock: entry = operations.lookup(parent, name, ctx) ret = fuse_reply_entry(req, &entry.fuse_param) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_lookup(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, ulong_t nlookup) with gil: try: with lock: operations.forget([(ino, nlookup)]) except: handle_exc(NULL) fuse_reply_none(req) cdef void fuse_forget_multi(fuse_req_t req, size_t count, fuse_forget_data *forgets) with gil: try: forget_list = list() for i in range(0, count): forget_list.append((forgets[i].ino, forgets[i].nlookup)) with lock: operations.forget(forget_list) except: handle_exc(NULL) fuse_reply_none(req) cdef void fuse_getattr (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret cdef EntryAttributes entry try: ctx = get_request_context(req) with lock: entry = operations.getattr(ino, ctx) ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_setattr (fuse_req_t req, fuse_ino_t ino, struct_stat *stat, int to_set, fuse_file_info *fi) with gil: cdef int ret cdef timespec now cdef EntryAttributes entry cdef SetattrFields fields cdef struct_stat *attr try: ctx = get_request_context(req) entry = EntryAttributes() fields = SetattrFields.__new__(SetattrFields) string.memcpy(entry.attr, stat, sizeof(struct_stat)) attr = entry.attr if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): ret = gettime_realtime(&now) if ret != 0: log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', strerror(errno.errno)) if to_set & FUSE_SET_ATTR_ATIME: fields.update_atime = True elif to_set & FUSE_SET_ATTR_ATIME_NOW: fields.update_atime = True attr.st_atime = now.tv_sec SET_ATIME_NS(attr, now.tv_nsec) if to_set & FUSE_SET_ATTR_MTIME: fields.update_mtime = True elif to_set & FUSE_SET_ATTR_MTIME_NOW: fields.update_mtime = True attr.st_mtime = now.tv_sec SET_MTIME_NS(attr, now.tv_nsec) fields.update_mode = bool(to_set & FUSE_SET_ATTR_MODE) fields.update_uid = bool(to_set & FUSE_SET_ATTR_UID) fields.update_gid = bool(to_set & FUSE_SET_ATTR_GID) fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) if fi is NULL: fh = None else: fh = fi.fh with lock: entry = operations.setattr(ino, entry, fields, fh, ctx) ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_readlink (fuse_req_t req, fuse_ino_t ino) with gil: cdef int ret cdef char* name try: ctx = get_request_context(req) with lock: target = operations.readlink(ino, ctx) name = PyBytes_AsString(target) ret = fuse_reply_readlink(req, name) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_mknod (fuse_req_t req, fuse_ino_t parent, const_char *name, mode_t mode, dev_t rdev) with gil: cdef int ret cdef EntryAttributes entry try: ctx = get_request_context(req) with lock: entry = operations.mknod(parent, PyBytes_FromString(name), mode, rdev, ctx) ret = fuse_reply_entry(req, &entry.fuse_param) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_mkdir (fuse_req_t req, fuse_ino_t parent, const_char *name, mode_t mode) with gil: cdef int ret cdef EntryAttributes entry try: # Force the entry type to directory. We need to explicitly cast, # because on BSD the S_* are not of type mode_t. mode = (mode & ~ S_IFMT) | S_IFDIR ctx = get_request_context(req) with lock: entry = operations.mkdir(parent, PyBytes_FromString(name), mode, ctx) ret = fuse_reply_entry(req, &entry.fuse_param) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_unlink (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: cdef int ret try: ctx = get_request_context(req) with lock: operations.unlink(parent, PyBytes_FromString(name), ctx) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_rmdir (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: cdef int ret try: ctx = get_request_context(req) with lock: operations.rmdir(parent, PyBytes_FromString(name), ctx) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_symlink (fuse_req_t req, const_char *link, fuse_ino_t parent, const_char *name) with gil: cdef int ret cdef EntryAttributes entry try: ctx = get_request_context(req) with lock: entry = operations.symlink(parent, PyBytes_FromString(name), PyBytes_FromString(link), ctx) ret = fuse_reply_entry(req, &entry.fuse_param) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_rename (fuse_req_t req, fuse_ino_t parent, const_char *name, fuse_ino_t newparent, const_char *newname) with gil: cdef int ret try: ctx = get_request_context(req) with lock: operations.rename(parent, PyBytes_FromString(name), newparent, PyBytes_FromString(newname), ctx) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_link (fuse_req_t req, fuse_ino_t ino, fuse_ino_t newparent, const_char *newname) with gil: cdef int ret cdef EntryAttributes entry try: ctx = get_request_context(req) with lock: entry = operations.link(ino, newparent, PyBytes_FromString(newname), ctx) ret = fuse_reply_entry(req, &entry.fuse_param) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_open (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret try: ctx = get_request_context(req) with lock: fi.fh = operations.open(ino, fi.flags, ctx) # Cached file data does not need to be invalidated. # http://article.gmane.org/gmane.comp.file-systems.fuse.devel/5325/ fi.keep_cache = 1 ret = fuse_reply_open(req, fi) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_read (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, fuse_file_info *fi) with gil: cdef int ret cdef Py_buffer pybuf try: with lock: buf = operations.read(fi.fh, off, size) PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) with nogil: ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) PyBuffer_Release(&pybuf) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_write (fuse_req_t req, fuse_ino_t ino, const_char *buf, size_t size, off_t off, fuse_file_info *fi) with gil: cdef int ret cdef size_t len_ try: if size > PY_SSIZE_T_MAX: raise OverflowError('Value too long to convert to Python') pbuf = PyBytes_FromStringAndSize(buf, size) # `with` statement may theoretically swallow exception, so we have to # initialize len_ to prevent gcc warning about it potentially # not initialized. len_ = 0 with lock: len_ = operations.write(fi.fh, off, pbuf) ret = fuse_reply_write(req, len_) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_write_buf(fuse_req_t req, fuse_ino_t ino, fuse_bufvec *bufv, off_t off, fuse_file_info *fi) with gil: cdef int ret cdef size_t len_ try: # `with` statement may theoretically swallow exception, so we have to # initialize len_ to prevent gcc warning about it potentially # not initialized. len_ = 0 buf = PyBytes_from_bufvec(bufv) with lock: len_ = operations.write(fi.fh, off, buf) ret = fuse_reply_write(req, len_) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_flush (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret try: with lock: operations.flush(fi.fh) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_release (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret try: with lock: operations.release(fi.fh) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_fsync (fuse_req_t req, fuse_ino_t ino, int datasync, fuse_file_info *fi) with gil: cdef int ret try: with lock: operations.fsync(fi.fh, datasync != 0) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_opendir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret try: ctx = get_request_context(req) with lock: fi.fh = operations.opendir(ino, ctx) ret = fuse_reply_open(req, fi) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_readdir (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, fuse_file_info *fi) with gil: cdef int ret cdef char *cname cdef char *buf cdef size_t len_, acc_size cdef EntryAttributes entry try: acc_size = 0 buf = NULL with lock: for (name, attr, next_) in operations.readdir(fi.fh, off): entry = attr if buf == NULL: buf = calloc_or_raise(size, sizeof(char)) cname = PyBytes_AsString(name) len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, cname, entry.attr, next_) if len_ > (size - acc_size): break acc_size += len_ ret = fuse_reply_buf(req, buf, acc_size) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) finally: if buf != NULL: stdlib.free(buf) if ret != 0: log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_releasedir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: cdef int ret try: with lock: operations.releasedir(fi.fh) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_releasedir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_fsyncdir (fuse_req_t req, fuse_ino_t ino, int datasync, fuse_file_info *fi) with gil: cdef int ret try: with lock: operations.fsyncdir(fi.fh, datasync != 0) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_fsyncdir(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_statfs (fuse_req_t req, fuse_ino_t ino) with gil: cdef int ret cdef StatvfsData stats # We don't set all the components try: ctx = get_request_context(req) with lock: stats = operations.statfs(ctx) ret = fuse_reply_statfs(req, &stats.stat) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_setxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, const_char *cvalue, size_t size, int flags, uint32_t position) with gil: cdef int ret if position != 0: log.error('fuse_setxattr(): non-zero position (%d) not supported', position) ret = fuse_reply_err(req, errno.EIO) if ret != 0: log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) return # Filter out flags that don't make any sense for a FUSE # file system, but that FUSE4x nevertheless stupidly # passes through. # (cf. https://groups.google.com/d/msg/fuse4x/bRnh7J_nsts/Z7raJ06DB4sJ) flags &= ~(XATTR_NOFOLLOW | XATTR_NODEFAULT | XATTR_NOSECURITY) fuse_setxattr(req, ino, cname, cvalue, size, flags) cdef void fuse_setxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, const_char *cvalue, size_t size, int flags) with gil: cdef int ret try: ctx = get_request_context(req) name = PyBytes_FromString(cname) if size > PY_SSIZE_T_MAX: raise OverflowError('Value too long to convert to Python') value = PyBytes_FromStringAndSize(cvalue, size) # Special case for deadlock debugging if ino == FUSE_ROOT_ID and string.strcmp(cname, 'fuse_stacktrace') == 0: operations.stacktrace() else: if PLATFORM == PLATFORM_DARWIN: # No known flags with lock: operations.setxattr(ino, name, value, ctx) else: # Make sure we know all the flags if flags & ~(XATTR_CREATE | XATTR_REPLACE): raise ValueError('unknown flag(s): %o' % flags) with lock: if flags & XATTR_CREATE: # Attribute must not exist try: operations.getxattr(ino, name) except FUSEError as e: if e.errno != ENOATTR: raise else: raise FUSEError(errno.EEXIST) elif flags & XATTR_REPLACE: # Attribute must exist operations.getxattr(ino, name) operations.setxattr(ino, name, value, ctx) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_getxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, size_t size, uint32_t position) with gil: cdef int ret if position != 0: log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) ret = fuse_reply_err(req, errno.EIO) if ret != 0: log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) else: fuse_getxattr(req, ino, cname, size) cdef void fuse_getxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, size_t size) with gil: cdef int ret cdef ssize_t len_s cdef size_t len_ cdef char *cbuf try: ctx = get_request_context(req) name = PyBytes_FromString(cname) with lock: buf = operations.getxattr(ino, name, ctx) PyBytes_AsStringAndSize(buf, &cbuf, &len_s) len_ = len_s # guaranteed positive if size == 0: ret = fuse_reply_xattr(req, len_) elif len_ <= size: ret = fuse_reply_buf(req, cbuf, len_) else: ret = fuse_reply_err(req, errno.ERANGE) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_listxattr (fuse_req_t req, fuse_ino_t ino, size_t size) with gil: cdef int ret cdef ssize_t len_s cdef size_t len_ cdef char *cbuf try: ctx = get_request_context(req) with lock: buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' PyBytes_AsStringAndSize(buf, &cbuf, &len_s) len_ = len_s # guaranteed positive if len_ == 1: # No attributes len_ = 0 if size == 0: ret = fuse_reply_xattr(req, len_) elif len_ <= size: ret = fuse_reply_buf(req, cbuf, len_) else: ret = fuse_reply_err(req, errno.ERANGE) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: cdef int ret try: ctx = get_request_context(req) name = PyBytes_FromString(cname) with lock: operations.removexattr(ino, name, ctx) ret = fuse_reply_err(req, 0) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_access (fuse_req_t req, fuse_ino_t ino, int mask) with gil: cdef int ret try: ctx = get_request_context(req) with lock: allowed = operations.access(ino, mask, ctx) if allowed: ret = fuse_reply_err(req, 0) else: ret = fuse_reply_err(req, EPERM) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_access(): fuse_reply_* failed with %s', strerror(-ret)) cdef void fuse_create (fuse_req_t req, fuse_ino_t parent, const_char *cname, mode_t mode, fuse_file_info *fi) with gil: cdef int ret cdef EntryAttributes entry try: ctx = get_request_context(req) name = PyBytes_FromString(cname) with lock: tmp = operations.create(parent, name, mode, fi.flags, ctx) fi.fh = tmp[0] entry = tmp[1] # Cached file data does not need to be invalidated. # http://article.gmane.org/gmane.comp.file-systems.fuse.devel/5325/ fi.keep_cache = 1 ret = fuse_reply_create(req, &entry.fuse_param, fi) except FUSEError as e: ret = fuse_reply_err(req, e.errno) except: ret = handle_exc(req) if ret != 0: log.error('fuse_create(): fuse_reply_* failed with %s', strerror(-ret)) llfuse-1.3.3/src/fuse_api.pxi0000664000175000017500000005077213240070532017607 0ustar nikrationikratio00000000000000''' fuse_api.pxi This file defines the Python bindings to common FUSE API functions. It is included by llfuse.pyx. Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' def listdir(path): '''Like `os.listdir`, but releases the GIL. This function returns an iterator over the directory entries in *path*. The returned values are of type :ref:`str ` in both Python 2.x and 3.x. In Python 2.x :class:`str` is equivalent to `bytes` so all names can be represented. In Python 3.x, surrogate escape coding (cf. `PEP 383 `_) is used for directory names that do not have a string representation. ''' if not isinstance(path, str_t): raise TypeError('*path* argument must be of type str') cdef dirent.DIR* dirp cdef dirent.dirent* res cdef char* buf path_b = str2bytes(path) buf = path_b with nogil: dirp = dirent.opendir(buf) if dirp == NULL: raise OSError(errno.errno, strerror(errno.errno), path) names = list() while True: errno.errno = 0 with nogil: res = dirent.readdir(dirp) if res is NULL: if errno.errno != 0: raise OSError(errno.errno, strerror(errno.errno), path) else: break if string.strcmp(res.d_name, b'.') == 0 or \ string.strcmp(res.d_name, b'..') == 0: continue names.append(bytes2str(PyBytes_FromString(res.d_name))) with nogil: dirent.closedir(dirp) return names def setxattr(path, name, bytes value, namespace='user'): '''Set extended attribute *path* and *name* have to be of type `str`. In Python 3.x, they may contain surrogates. *value* has to be of type `bytes`. Under FreeBSD, the *namespace* parameter may be set to *system* or *user* to select the namespace for the extended attribute. For other platforms, this parameter is ignored. In contrast the `os.setxattr` function from the standard library, the method provided by Python-LLFUSE is also available for non-Linux systems. ''' if not isinstance(path, str_t): raise TypeError('*path* argument must be of type str') if not isinstance(name, str_t): raise TypeError('*name* argument must be of type str') if namespace not in ('system', 'user'): raise ValueError('*namespace* parameter must be "system" or "user", not %s' % namespace) cdef int ret cdef Py_ssize_t len_ cdef char *cvalue cdef char *cpath cdef char *cname cdef int cnamespace if namespace == 'system': cnamespace = EXTATTR_NAMESPACE_SYSTEM else: cnamespace = EXTATTR_NAMESPACE_USER path_b = str2bytes(path) name_b = str2bytes(name) PyBytes_AsStringAndSize(value, &cvalue, &len_) cpath = path_b cname = name_b with nogil: # len_ is guaranteed positive ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) if ret != 0: raise OSError(errno.errno, strerror(errno.errno), path) def getxattr(path, name, size_t size_guess=128, namespace='user'): '''Get extended attribute *path* and *name* have to be of type `str`. In Python 3.x, they may contain surrogates. Returns a value of type `bytes`. If the caller knows the approximate size of the attribute value, it should be supplied in *size_guess*. If the guess turns out to be wrong, the system call has to be carried out three times (the first call will fail, the second determines the size and the third finally gets the value). Under FreeBSD, the *namespace* parameter may be set to *system* or *user* to select the namespace for the extended attribute. For other platforms, this parameter is ignored. In contrast the `os.setxattr` function from the standard library, the method provided by Python-LLFUSE is also available for non-Linux systems. ''' if not isinstance(path, str_t): raise TypeError('*path* argument must be of type str') if not isinstance(name, str_t): raise TypeError('*name* argument must be of type str') if namespace not in ('system', 'user'): raise ValueError('*namespace* parameter must be "system" or "user", not %s' % namespace) cdef ssize_t ret cdef char *buf cdef char *cpath cdef char *cname cdef size_t bufsize cdef int cnamespace if namespace == 'system': cnamespace = EXTATTR_NAMESPACE_SYSTEM else: cnamespace = EXTATTR_NAMESPACE_USER path_b = str2bytes(path) name_b = str2bytes(name) cpath = path_b cname = name_b bufsize = size_guess buf = stdlib.malloc(bufsize * sizeof(char)) if buf is NULL: cpython.exc.PyErr_NoMemory() try: with nogil: ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) if ret < 0 and errno.errno == errno.ERANGE: with nogil: ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) if ret < 0: raise OSError(errno.errno, strerror(errno.errno), path) bufsize = ret stdlib.free(buf) buf = stdlib.malloc(bufsize * sizeof(char)) if buf is NULL: cpython.exc.PyErr_NoMemory() with nogil: ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) if ret < 0: raise OSError(errno.errno, strerror(errno.errno), path) return PyBytes_FromStringAndSize(buf, ret) finally: stdlib.free(buf) # Default options: # # * splice_write just means to use splice if possible (i.e., if data is passed # in a fd), and can be overriden using FUSE_BUF_NO_SPLICE. So it's a good idea # to always activate it. # # * splice_read means that requests are spliced from the fuse fd to a # (thread-specific) intermediate pipe (this is presumably done to prevent the # write handler from reading part of the next request). If splice_read is not # set, fuse instead reads the whole request into memory and passes this buffer # along. If we eventually read the request into a buffer anyway (as we have # to if we want to create a Python object), using splice_read() is thus # expected to *decrease* performance because of the intermediate pipe. # # * splice_move is a no-op as of Linux 2.6.21. However, it will become active as # soon as some problems with the initial implementation have been solved. If # active, it's expected to improve performance because we move pages from the # page instead of copying them. # if os.uname()[0] == 'Darwin': default_options = frozenset(('big_writes', 'default_permissions', 'no_splice_read', 'splice_write', 'splice_move')) else: default_options = frozenset(('big_writes', 'nonempty', 'default_permissions', 'no_splice_read', 'splice_write', 'splice_move')) def init(ops, mountpoint, options=default_options): '''Initialize and mount FUSE file system *ops* has to be an instance of the `Operations` class (or another class defining the same methods). *args* has to be a set of strings. `default_options` provides some reasonable defaults. It is recommended to use these options as a basis and add or remove options as necessary. For example:: my_opts = set(llfuse.default_options) my_opts.add('allow_other') my_opts.discard('default_permissions') llfuse.init(ops, mountpoint, my_opts) Valid options are listed under ``struct fuse_opt fuse_mount_opts[]`` (`mount.c:82 `_) and ``struct fuse_opt fuse_ll_opts[]`` (`fuse_lowlevel_c:2626 `_). ''' log.debug('Initializing llfuse') cdef fuse_args f_args if not isinstance(mountpoint, str_t): raise TypeError('*mountpoint_* argument must be of type str') global operations global fuse_ops global mountpoint_b global session global channel mountpoint_b = str2bytes(os.path.abspath(mountpoint)) operations = ops make_fuse_args(options, &f_args) log.debug('Calling fuse_mount') channel = fuse_mount(mountpoint_b, &f_args) if not channel: raise RuntimeError('fuse_mount failed') log.debug('Calling fuse_lowlevel_new') init_fuse_ops() session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) if not session: fuse_unmount(mountpoint_b, channel) raise RuntimeError("fuse_lowlevel_new() failed") log.debug('Calling fuse_session_add_chan') fuse_session_add_chan(session, channel) pthread_mutex_init(&exc_info_mutex, NULL) def main(workers=None): '''Run FUSE main loop *workers* specifies the number of threads that will process requests concurrently. If *workers* is `None`, llfuse will pick a reasonable number bigger than one. If *workers* is ``1`` all requests will be processed by the thread calling `main`. This function will also start additional threads for internal purposes (even if *workers* is ``1``). These (and all worker threads) are guaranteed to have terminated when `main` returns. While this function is running, special signal handlers will be installed for the *SIGTERM*, *SIGINT* (Ctrl-C), *SIGHUP*, *SIGUSR1* and *SIGPIPE* signals. *SIGPIPE* will be ignored, while the other three signals will cause request processing to stop and the function to return. *SIGINT* (Ctrl-C) will thus *not* result in a `KeyboardInterrupt` exception while this function is runnning. When the function returns because the file system has received an unmount request it will return `None`. If it returns because it has received a signal, it will return the signal number. ''' global exc_info global exit_reason if session == NULL: raise RuntimeError('Need to call init() before main()') if workers == 0: raise ValueError('No workers is not a good idea') if workers is None: # We may add some smartness here later. workers = 30 # SIGKILL cannot be caught, so we can use it as a placeholder # for "regular exit". exit_reason = signal.SIGKILL with contextlib.ExitStack() as on_exit: set_signal_handlers() on_exit.callback(lambda: restore_signal_handlers()) # Start notification handling thread t = threading.Thread(target=_notify_loop) t.daemon = True t.start() on_exit.callback(_notify_queue.put, None, block=True, timeout=5) on_exit.callback(lambda: fuse_session_reset(session)) exc_info = None log.debug('Calling fuse_session_loop') if workers == 1: session_loop_single() else: session_loop_mt(workers) if exc_info: # Re-raise expression from request handler log.debug('Terminated main loop because request handler raised exception, re-raising..') tmp = exc_info exc_info = None # The explicit version check works around a Cython bug with # the 3-parameter version of the raise statement, c.f. # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 if PY_MAJOR_VERSION < 3: raise tmp[0], tmp[1], tmp[2] else: raise tmp[1].with_traceback(tmp[2]) if exit_reason == signal.SIGKILL: return None else: return exit_reason cdef session_loop_single(): cdef void* mem cdef size_t size size = fuse_chan_bufsize(channel) mem = calloc_or_raise(1, size) try: session_loop(mem, size) finally: stdlib.free(mem) cdef session_loop(void* mem, size_t size): '''Process requests''' cdef int res cdef fuse_chan *ch cdef fuse_buf buf while not fuse_session_exited(session): ch = channel buf.mem = mem buf.size = size buf.pos = 0 buf.flags = 0 with nogil: res = fuse_session_receive_buf(session, &buf, &ch) if res == -errno.EINTR: continue elif res < 0: raise OSError(-res, 'fuse_session_receive_buf failed with ' + strerror(-res)) elif res == 0: break fuse_session_process_buf(session, &buf, ch) ctypedef struct worker_data_t: sem_t* sem int thread_no int started pthread_t thread_id void* buf size_t bufsize cdef void* worker_start(void* data) with gil: cdef worker_data_t *wd cdef int res global exc_info wd = data t = threading.current_thread() t.name = 'fuse-worker-%d' % (wd.thread_no+1,) try: session_loop(wd.buf, wd.bufsize) except: fuse_session_exit(session) log.error('FUSE worker thread %d terminated with exception, ' 'aborting processing', wd.thread_id) res = pthread_mutex_lock(&exc_info_mutex) if res != 0: log.error('pthread_mutex_lock failed with %s', strerror(res)) if not exc_info: exc_info = sys.exc_info() else: log.exception('Only one exception can be re-raised, the following ' 'exception will be lost:') pthread_mutex_unlock(&exc_info_mutex) if res != 0: log.error('pthread_mutex_ulock failed with %s', strerror(res)) finally: sem_post(wd.sem) cdef session_loop_mt(workers): cdef worker_data_t *wd cdef sigset_t newset, oldset cdef int res, i cdef size_t bufsize cdef sem_t sem if sem_init(&sem, 0, 0) != 0: raise OSError(errno.errno, 'sem_init failed with ' + strerror(errno.errno)) sigemptyset(&newset); sigaddset(&newset, signal.SIGTERM); sigaddset(&newset, signal.SIGINT); sigaddset(&newset, signal.SIGHUP); sigaddset(&newset, signal.SIGQUIT); PyEval_InitThreads() bufsize = fuse_chan_bufsize(channel) wd = calloc_or_raise(workers, sizeof(worker_data_t)) try: for i in range(workers): wd[i].sem = &sem wd[i].thread_no = i wd[i].bufsize = bufsize wd[i].buf = calloc_or_raise(1, bufsize) # Ensure that signals get delivered to main thread pthread_sigmask(SIG_BLOCK, &newset, &oldset) res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) pthread_sigmask(SIG_SETMASK, &oldset, NULL) if res != 0: raise OSError(res, 'pthread_create failed with ' + strerror(res)) wd[i].started = 1 with nogil: while not fuse_session_exited(session): sem_wait(&sem) # also interrupted by signals finally: for i in range(workers): if wd[i].started: res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) # Thread may have terminated already if res != 0 and res != errno.ESRCH: log.error('pthread_kill failed with: %s', strerror(res)) with nogil: res = pthread_join(wd[i].thread_id, NULL) if res != 0: log.error('pthread_join failed with: %s', strerror(res)) if wd[i].buf != NULL: stdlib.free(wd[i].buf) stdlib.free(wd) def close(unmount=True): '''Clean up and ensure filesystem is unmounted If *unmount* is False, only clean up operations are peformed, but the file system is not explicitly unmounted. Normally, the filesystem is unmounted by the user calling umount(8) or fusermount(1), which then terminates the FUSE main loop. However, the loop may also terminate as a result of an exception or a signal. In this case the filesystem remains mounted, but any attempt to access it will block (while the filesystem process is still running) or (after the filesystem process has terminated) return an error. If *unmount* is True, this function will ensure that the filesystem is properly unmounted. Note: if the connection to the kernel is terminated via the ``/sys/fs/fuse/connections/`` interface, this function will *not* unmount the filesystem even if *unmount* is True. ''' global mountpoint_b global session global channel global exc_info log.debug('Calling fuse_session_remove_chan') fuse_session_remove_chan(channel) log.debug('Calling fuse_session_destroy') fuse_session_destroy(session) if unmount: log.debug('Calling fuse_unmount') fuse_unmount(mountpoint_b, channel) else: fuse_chan_destroy(channel) mountpoint_b = None session = NULL channel = NULL # destroy handler may have given us an exception if exc_info: tmp = exc_info exc_info = None # The explicit version check works around a Cython bug with # the 3-parameter version of the raise statement, c.f. # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 if PY_MAJOR_VERSION < 3: raise tmp[0], tmp[1], tmp[2] else: raise tmp[1].with_traceback(tmp[2]) def invalidate_inode(fuse_ino_t inode, attr_only=False): '''Invalidate cache for *inode* Instructs the FUSE kernel module to forgot cached attributes and data (unless *attr_only* is True) for *inode*. This operation is carried out asynchronously, i.e. the method may return before the kernel has executed the request. ''' cdef NotifyRequest req req = NotifyRequest.__new__(NotifyRequest) req.kind = NOTIFY_INVAL_INODE req.ino = inode req.attr_only = bool(attr_only) _notify_queue.put(req) def invalidate_entry(fuse_ino_t inode_p, bytes name): '''Invalidate directory entry Instructs the FUSE kernel module to forget about the directory entry *name* in the directory with inode *inode_p*. This operation is carried out asynchronously, i.e. the method may return before the kernel has executed the request. ''' cdef NotifyRequest req req = NotifyRequest.__new__(NotifyRequest) req.kind = NOTIFY_INVAL_ENTRY req.ino = inode_p req.name = name _notify_queue.put(req) def get_ino_t_bits(): '''Return number of bits available for inode numbers Attempts to use inode values that need more bytes will result in `OverflowError`. ''' return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 def get_off_t_bits(): '''Return number of bytes available for file offsets Attempts to use values whose representation needs more bytes will result in `OverflowError`. ''' return sizeof(off_t) * 8 def notify_store(inode, offset, data): '''Store data in kernel page cache Sends *data* for the kernel to store it in the page cache for *inode* at *offset*. If this provides data beyond the current file size, the file is automatically extended. If this function raises an exception, the store may still have completed partially. ''' cdef int ret cdef fuse_ino_t ino cdef off_t off cdef Py_buffer pybuf cdef fuse_bufvec bufvec cdef fuse_buf *buf PyObject_GetBuffer(data, &pybuf, PyBUF_CONTIG_RO) bufvec.count = 1 bufvec.idx = 0 bufvec.off = 0 buf = bufvec.buf buf[0].flags = 0 buf[0].mem = pybuf.buf buf[0].size = pybuf.len # guaranteed positive ino = inode off = offset with nogil: ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) PyBuffer_Release(&pybuf) if ret != 0: raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) def get_sup_groups(pid): '''Return supplementary group ids of *pid* This function is relatively expensive because it has to read the group ids from ``/proc/[pid]/status``. For the same reason, it will also not work on systems that do not provide a ``/proc`` file system. Returns a set. ''' with open('/proc/%d/status' % pid, 'r') as fh: for line in fh: if line.startswith('Groups:'): break else: raise RuntimeError("Unable to parse %s" % fh.name) gids = set() for x in line.split()[1:]: gids.add(int(x)) return gids llfuse-1.3.3/src/llfuse.c0000664000175000017500001051225313257663561016750 0ustar nikrationikratio00000000000000/* Generated by Cython 0.25.2 */ #define PY_SSIZE_T_CLEAN #include "Python.h" #ifndef Py_PYTHON_H #error Python headers needed to compile C extensions, please install development version of Python. #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03020000) #error Cython requires Python 2.6+ or Python 3.2+. #else #define CYTHON_ABI "0_25_2" #include #ifndef offsetof #define offsetof(type, member) ( (size_t) & ((type*)0) -> member ) #endif #if !defined(WIN32) && !defined(MS_WINDOWS) #ifndef __stdcall #define __stdcall #endif #ifndef __cdecl #define __cdecl #endif #ifndef __fastcall #define __fastcall #endif #endif #ifndef DL_IMPORT #define DL_IMPORT(t) t #endif #ifndef DL_EXPORT #define DL_EXPORT(t) t #endif #ifndef HAVE_LONG_LONG #if PY_VERSION_HEX >= 0x03030000 || (PY_MAJOR_VERSION == 2 && PY_VERSION_HEX >= 0x02070000) #define HAVE_LONG_LONG #endif #endif #ifndef PY_LONG_LONG #define PY_LONG_LONG LONG_LONG #endif #ifndef Py_HUGE_VAL #define Py_HUGE_VAL HUGE_VAL #endif #ifdef PYPY_VERSION #define CYTHON_COMPILING_IN_PYPY 1 #define CYTHON_COMPILING_IN_PYSTON 0 #define CYTHON_COMPILING_IN_CPYTHON 0 #undef CYTHON_USE_TYPE_SLOTS #define CYTHON_USE_TYPE_SLOTS 0 #undef CYTHON_USE_ASYNC_SLOTS #define CYTHON_USE_ASYNC_SLOTS 0 #undef CYTHON_USE_PYLIST_INTERNALS #define CYTHON_USE_PYLIST_INTERNALS 0 #undef CYTHON_USE_UNICODE_INTERNALS #define CYTHON_USE_UNICODE_INTERNALS 0 #undef CYTHON_USE_UNICODE_WRITER #define CYTHON_USE_UNICODE_WRITER 0 #undef CYTHON_USE_PYLONG_INTERNALS #define CYTHON_USE_PYLONG_INTERNALS 0 #undef CYTHON_AVOID_BORROWED_REFS #define CYTHON_AVOID_BORROWED_REFS 1 #undef CYTHON_ASSUME_SAFE_MACROS #define CYTHON_ASSUME_SAFE_MACROS 0 #undef CYTHON_UNPACK_METHODS #define CYTHON_UNPACK_METHODS 0 #undef CYTHON_FAST_THREAD_STATE #define CYTHON_FAST_THREAD_STATE 0 #undef CYTHON_FAST_PYCALL #define CYTHON_FAST_PYCALL 0 #elif defined(PYSTON_VERSION) #define CYTHON_COMPILING_IN_PYPY 0 #define CYTHON_COMPILING_IN_PYSTON 1 #define CYTHON_COMPILING_IN_CPYTHON 0 #ifndef CYTHON_USE_TYPE_SLOTS #define CYTHON_USE_TYPE_SLOTS 1 #endif #undef CYTHON_USE_ASYNC_SLOTS #define CYTHON_USE_ASYNC_SLOTS 0 #undef CYTHON_USE_PYLIST_INTERNALS #define CYTHON_USE_PYLIST_INTERNALS 0 #ifndef CYTHON_USE_UNICODE_INTERNALS #define CYTHON_USE_UNICODE_INTERNALS 1 #endif #undef CYTHON_USE_UNICODE_WRITER #define CYTHON_USE_UNICODE_WRITER 0 #undef CYTHON_USE_PYLONG_INTERNALS #define CYTHON_USE_PYLONG_INTERNALS 0 #ifndef CYTHON_AVOID_BORROWED_REFS #define CYTHON_AVOID_BORROWED_REFS 0 #endif #ifndef CYTHON_ASSUME_SAFE_MACROS #define CYTHON_ASSUME_SAFE_MACROS 1 #endif #ifndef CYTHON_UNPACK_METHODS #define CYTHON_UNPACK_METHODS 1 #endif #undef CYTHON_FAST_THREAD_STATE #define CYTHON_FAST_THREAD_STATE 0 #undef CYTHON_FAST_PYCALL #define CYTHON_FAST_PYCALL 0 #else #define CYTHON_COMPILING_IN_PYPY 0 #define CYTHON_COMPILING_IN_PYSTON 0 #define CYTHON_COMPILING_IN_CPYTHON 1 #ifndef CYTHON_USE_TYPE_SLOTS #define CYTHON_USE_TYPE_SLOTS 1 #endif #if PY_MAJOR_VERSION < 3 #undef CYTHON_USE_ASYNC_SLOTS #define CYTHON_USE_ASYNC_SLOTS 0 #elif !defined(CYTHON_USE_ASYNC_SLOTS) #define CYTHON_USE_ASYNC_SLOTS 1 #endif #if PY_VERSION_HEX < 0x02070000 #undef CYTHON_USE_PYLONG_INTERNALS #define CYTHON_USE_PYLONG_INTERNALS 0 #elif !defined(CYTHON_USE_PYLONG_INTERNALS) #define CYTHON_USE_PYLONG_INTERNALS 1 #endif #ifndef CYTHON_USE_PYLIST_INTERNALS #define CYTHON_USE_PYLIST_INTERNALS 1 #endif #ifndef CYTHON_USE_UNICODE_INTERNALS #define CYTHON_USE_UNICODE_INTERNALS 1 #endif #if PY_VERSION_HEX < 0x030300F0 #undef CYTHON_USE_UNICODE_WRITER #define CYTHON_USE_UNICODE_WRITER 0 #elif !defined(CYTHON_USE_UNICODE_WRITER) #define CYTHON_USE_UNICODE_WRITER 1 #endif #ifndef CYTHON_AVOID_BORROWED_REFS #define CYTHON_AVOID_BORROWED_REFS 0 #endif #ifndef CYTHON_ASSUME_SAFE_MACROS #define CYTHON_ASSUME_SAFE_MACROS 1 #endif #ifndef CYTHON_UNPACK_METHODS #define CYTHON_UNPACK_METHODS 1 #endif #ifndef CYTHON_FAST_THREAD_STATE #define CYTHON_FAST_THREAD_STATE 1 #endif #ifndef CYTHON_FAST_PYCALL #define CYTHON_FAST_PYCALL 1 #endif #endif #if !defined(CYTHON_FAST_PYCCALL) #define CYTHON_FAST_PYCCALL (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1) #endif #if CYTHON_USE_PYLONG_INTERNALS #include "longintrepr.h" #undef SHIFT #undef BASE #undef MASK #endif #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag) #define Py_OptimizeFlag 0 #endif #define __PYX_BUILD_PY_SSIZE_T "n" #define CYTHON_FORMAT_SSIZE_T "z" #if PY_MAJOR_VERSION < 3 #define __Pyx_BUILTIN_MODULE_NAME "__builtin__" #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\ PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) #define __Pyx_DefaultClassType PyClass_Type #else #define __Pyx_BUILTIN_MODULE_NAME "builtins" #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\ PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos) #define __Pyx_DefaultClassType PyType_Type #endif #ifndef Py_TPFLAGS_CHECKTYPES #define Py_TPFLAGS_CHECKTYPES 0 #endif #ifndef Py_TPFLAGS_HAVE_INDEX #define Py_TPFLAGS_HAVE_INDEX 0 #endif #ifndef Py_TPFLAGS_HAVE_NEWBUFFER #define Py_TPFLAGS_HAVE_NEWBUFFER 0 #endif #ifndef Py_TPFLAGS_HAVE_FINALIZE #define Py_TPFLAGS_HAVE_FINALIZE 0 #endif #ifndef METH_FASTCALL #define METH_FASTCALL 0x80 typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *self, PyObject **args, Py_ssize_t nargs, PyObject *kwnames); #else #define __Pyx_PyCFunctionFast _PyCFunctionFast #endif #if CYTHON_FAST_PYCCALL #define __Pyx_PyFastCFunction_Check(func)\ ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST))))) #else #define __Pyx_PyFastCFunction_Check(func) 0 #endif #if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND) #define CYTHON_PEP393_ENABLED 1 #define __Pyx_PyUnicode_READY(op) (likely(PyUnicode_IS_READY(op)) ?\ 0 : _PyUnicode_Ready((PyObject *)(op))) #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_LENGTH(u) #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i) #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) PyUnicode_MAX_CHAR_VALUE(u) #define __Pyx_PyUnicode_KIND(u) PyUnicode_KIND(u) #define __Pyx_PyUnicode_DATA(u) PyUnicode_DATA(u) #define __Pyx_PyUnicode_READ(k, d, i) PyUnicode_READ(k, d, i) #define __Pyx_PyUnicode_WRITE(k, d, i, ch) PyUnicode_WRITE(k, d, i, ch) #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u))) #else #define CYTHON_PEP393_ENABLED 0 #define PyUnicode_1BYTE_KIND 1 #define PyUnicode_2BYTE_KIND 2 #define PyUnicode_4BYTE_KIND 4 #define __Pyx_PyUnicode_READY(op) (0) #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_SIZE(u) #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i])) #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111) #define __Pyx_PyUnicode_KIND(u) (sizeof(Py_UNICODE)) #define __Pyx_PyUnicode_DATA(u) ((void*)PyUnicode_AS_UNICODE(u)) #define __Pyx_PyUnicode_READ(k, d, i) ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i])) #define __Pyx_PyUnicode_WRITE(k, d, i, ch) (((void)(k)), ((Py_UNICODE*)d)[i] = ch) #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_SIZE(u)) #endif #if CYTHON_COMPILING_IN_PYPY #define __Pyx_PyUnicode_Concat(a, b) PyNumber_Add(a, b) #define __Pyx_PyUnicode_ConcatSafe(a, b) PyNumber_Add(a, b) #else #define __Pyx_PyUnicode_Concat(a, b) PyUnicode_Concat(a, b) #define __Pyx_PyUnicode_ConcatSafe(a, b) ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\ PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b)) #endif #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains) #define PyUnicode_Contains(u, s) PySequence_Contains(u, s) #endif #if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check) #define PyByteArray_Check(obj) PyObject_TypeCheck(obj, &PyByteArray_Type) #endif #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format) #define PyObject_Format(obj, fmt) PyObject_CallMethod(obj, "__format__", "O", fmt) #endif #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc) #define PyObject_Malloc(s) PyMem_Malloc(s) #define PyObject_Free(p) PyMem_Free(p) #define PyObject_Realloc(p) PyMem_Realloc(p) #endif #if CYTHON_COMPILING_IN_PYSTON #define __Pyx_PyCode_HasFreeVars(co) PyCode_HasFreeVars(co) #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno) #else #define __Pyx_PyCode_HasFreeVars(co) (PyCode_GetNumFree(co) > 0) #define __Pyx_PyFrame_SetLineNumber(frame, lineno) (frame)->f_lineno = (lineno) #endif #define __Pyx_PyString_FormatSafe(a, b) ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b)) #define __Pyx_PyUnicode_FormatSafe(a, b) ((unlikely((a) == Py_None)) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b)) #if PY_MAJOR_VERSION >= 3 #define __Pyx_PyString_Format(a, b) PyUnicode_Format(a, b) #else #define __Pyx_PyString_Format(a, b) PyString_Format(a, b) #endif #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII) #define PyObject_ASCII(o) PyObject_Repr(o) #endif #if PY_MAJOR_VERSION >= 3 #define PyBaseString_Type PyUnicode_Type #define PyStringObject PyUnicodeObject #define PyString_Type PyUnicode_Type #define PyString_Check PyUnicode_Check #define PyString_CheckExact PyUnicode_CheckExact #endif #if PY_MAJOR_VERSION >= 3 #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj) #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj) #else #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj)) #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj)) #endif #ifndef PySet_CheckExact #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type) #endif #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type) #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception) #if PY_MAJOR_VERSION >= 3 #define PyIntObject PyLongObject #define PyInt_Type PyLong_Type #define PyInt_Check(op) PyLong_Check(op) #define PyInt_CheckExact(op) PyLong_CheckExact(op) #define PyInt_FromString PyLong_FromString #define PyInt_FromUnicode PyLong_FromUnicode #define PyInt_FromLong PyLong_FromLong #define PyInt_FromSize_t PyLong_FromSize_t #define PyInt_FromSsize_t PyLong_FromSsize_t #define PyInt_AsLong PyLong_AsLong #define PyInt_AS_LONG PyLong_AS_LONG #define PyInt_AsSsize_t PyLong_AsSsize_t #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask #define PyNumber_Int PyNumber_Long #endif #if PY_MAJOR_VERSION >= 3 #define PyBoolObject PyLongObject #endif #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY #ifndef PyUnicode_InternFromString #define PyUnicode_InternFromString(s) PyUnicode_FromString(s) #endif #endif #if PY_VERSION_HEX < 0x030200A4 typedef long Py_hash_t; #define __Pyx_PyInt_FromHash_t PyInt_FromLong #define __Pyx_PyInt_AsHash_t PyInt_AsLong #else #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t #define __Pyx_PyInt_AsHash_t PyInt_AsSsize_t #endif #if PY_MAJOR_VERSION >= 3 #define __Pyx_PyMethod_New(func, self, klass) ((self) ? PyMethod_New(func, self) : PyInstanceMethod_New(func)) #else #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass) #endif #if CYTHON_USE_ASYNC_SLOTS #if PY_VERSION_HEX >= 0x030500B1 #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async) #else typedef struct { unaryfunc am_await; unaryfunc am_aiter; unaryfunc am_anext; } __Pyx_PyAsyncMethodsStruct; #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved)) #endif #else #define __Pyx_PyType_AsAsync(obj) NULL #endif #ifndef CYTHON_RESTRICT #if defined(__GNUC__) #define CYTHON_RESTRICT __restrict__ #elif defined(_MSC_VER) && _MSC_VER >= 1400 #define CYTHON_RESTRICT __restrict #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L #define CYTHON_RESTRICT restrict #else #define CYTHON_RESTRICT #endif #endif #ifndef CYTHON_UNUSED # if defined(__GNUC__) # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)) # define CYTHON_UNUSED __attribute__ ((__unused__)) # else # define CYTHON_UNUSED # endif # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER)) # define CYTHON_UNUSED __attribute__ ((__unused__)) # else # define CYTHON_UNUSED # endif #endif #ifndef CYTHON_MAYBE_UNUSED_VAR # if defined(__cplusplus) template void CYTHON_MAYBE_UNUSED_VAR( const T& ) { } # else # define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x) # endif #endif #ifndef CYTHON_NCP_UNUSED # if CYTHON_COMPILING_IN_CPYTHON # define CYTHON_NCP_UNUSED # else # define CYTHON_NCP_UNUSED CYTHON_UNUSED # endif #endif #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None) #ifndef CYTHON_INLINE #if defined(__clang__) #define CYTHON_INLINE __inline__ __attribute__ ((__unused__)) #elif defined(__GNUC__) #define CYTHON_INLINE __inline__ #elif defined(_MSC_VER) #define CYTHON_INLINE __inline #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L #define CYTHON_INLINE inline #else #define CYTHON_INLINE #endif #endif #if defined(WIN32) || defined(MS_WINDOWS) #define _USE_MATH_DEFINES #endif #include #ifdef NAN #define __PYX_NAN() ((float) NAN) #else static CYTHON_INLINE float __PYX_NAN() { float value; memset(&value, 0xFF, sizeof(value)); return value; } #endif #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL) #define __Pyx_truncl trunc #else #define __Pyx_truncl truncl #endif #define __PYX_ERR(f_index, lineno, Ln_error) \ { \ __pyx_filename = __pyx_f[f_index]; __pyx_lineno = lineno; __pyx_clineno = __LINE__; goto Ln_error; \ } #if PY_MAJOR_VERSION >= 3 #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y) #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y) #else #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y) #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y) #endif #ifndef __PYX_EXTERN_C #ifdef __cplusplus #define __PYX_EXTERN_C extern "C" #else #define __PYX_EXTERN_C extern #endif #endif #define __PYX_HAVE__llfuse #define __PYX_HAVE_API__llfuse #include "llfuse.h" #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "lock.h" #include "macros.c" #include "xattr.h" #include "gettime.h" #ifdef _OPENMP #include #endif /* _OPENMP */ #ifdef PYREX_WITHOUT_ASSERTIONS #define CYTHON_WITHOUT_ASSERTIONS #endif typedef struct {PyObject **p; const char *s; const Py_ssize_t n; const char* encoding; const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry; #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0 #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT 0 #define __PYX_DEFAULT_STRING_ENCODING "" #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize #define __Pyx_uchar_cast(c) ((unsigned char)c) #define __Pyx_long_cast(x) ((long)x) #define __Pyx_fits_Py_ssize_t(v, type, is_signed) (\ (sizeof(type) < sizeof(Py_ssize_t)) ||\ (sizeof(type) > sizeof(Py_ssize_t) &&\ likely(v < (type)PY_SSIZE_T_MAX ||\ v == (type)PY_SSIZE_T_MAX) &&\ (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\ v == (type)PY_SSIZE_T_MIN))) ||\ (sizeof(type) == sizeof(Py_ssize_t) &&\ (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\ v == (type)PY_SSIZE_T_MAX))) ) #if defined (__cplusplus) && __cplusplus >= 201103L #include #define __Pyx_sst_abs(value) std::abs(value) #elif SIZEOF_INT >= SIZEOF_SIZE_T #define __Pyx_sst_abs(value) abs(value) #elif SIZEOF_LONG >= SIZEOF_SIZE_T #define __Pyx_sst_abs(value) labs(value) #elif defined (_MSC_VER) && defined (_M_X64) #define __Pyx_sst_abs(value) _abs64(value) #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L #define __Pyx_sst_abs(value) llabs(value) #elif defined (__GNUC__) #define __Pyx_sst_abs(value) __builtin_llabs(value) #else #define __Pyx_sst_abs(value) ((value<0) ? -value : value) #endif static CYTHON_INLINE char* __Pyx_PyObject_AsString(PyObject*); static CYTHON_INLINE char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length); #define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s)) #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l) #define __Pyx_PyBytes_FromString PyBytes_FromString #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*); #if PY_MAJOR_VERSION < 3 #define __Pyx_PyStr_FromString __Pyx_PyBytes_FromString #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize #else #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize #endif #define __Pyx_PyObject_AsSString(s) ((signed char*) __Pyx_PyObject_AsString(s)) #define __Pyx_PyObject_AsUString(s) ((unsigned char*) __Pyx_PyObject_AsString(s)) #define __Pyx_PyObject_FromCString(s) __Pyx_PyObject_FromString((const char*)s) #define __Pyx_PyBytes_FromCString(s) __Pyx_PyBytes_FromString((const char*)s) #define __Pyx_PyByteArray_FromCString(s) __Pyx_PyByteArray_FromString((const char*)s) #define __Pyx_PyStr_FromCString(s) __Pyx_PyStr_FromString((const char*)s) #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s) #if PY_MAJOR_VERSION < 3 static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u) { const Py_UNICODE *u_end = u; while (*u_end++) ; return (size_t)(u_end - u - 1); } #else #define __Pyx_Py_UNICODE_strlen Py_UNICODE_strlen #endif #define __Pyx_PyUnicode_FromUnicode(u) PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u)) #define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode #define __Pyx_PyUnicode_AsUnicode PyUnicode_AsUnicode #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj) #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None) #define __Pyx_PyBool_FromLong(b) ((b) ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False)) static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*); static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x); static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*); static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t); #if CYTHON_ASSUME_SAFE_MACROS #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x)) #else #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x) #endif #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x)) #if PY_MAJOR_VERSION >= 3 #define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x)) #else #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x)) #endif #define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x)) #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII static int __Pyx_sys_getdefaultencoding_not_ascii; static int __Pyx_init_sys_getdefaultencoding_params(void) { PyObject* sys; PyObject* default_encoding = NULL; PyObject* ascii_chars_u = NULL; PyObject* ascii_chars_b = NULL; const char* default_encoding_c; sys = PyImport_ImportModule("sys"); if (!sys) goto bad; default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL); Py_DECREF(sys); if (!default_encoding) goto bad; default_encoding_c = PyBytes_AsString(default_encoding); if (!default_encoding_c) goto bad; if (strcmp(default_encoding_c, "ascii") == 0) { __Pyx_sys_getdefaultencoding_not_ascii = 0; } else { char ascii_chars[128]; int c; for (c = 0; c < 128; c++) { ascii_chars[c] = c; } __Pyx_sys_getdefaultencoding_not_ascii = 1; ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL); if (!ascii_chars_u) goto bad; ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL); if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) { PyErr_Format( PyExc_ValueError, "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.", default_encoding_c); goto bad; } Py_DECREF(ascii_chars_u); Py_DECREF(ascii_chars_b); } Py_DECREF(default_encoding); return 0; bad: Py_XDECREF(default_encoding); Py_XDECREF(ascii_chars_u); Py_XDECREF(ascii_chars_b); return -1; } #endif #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL) #else #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL) #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT static char* __PYX_DEFAULT_STRING_ENCODING; static int __Pyx_init_sys_getdefaultencoding_params(void) { PyObject* sys; PyObject* default_encoding = NULL; char* default_encoding_c; sys = PyImport_ImportModule("sys"); if (!sys) goto bad; default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL); Py_DECREF(sys); if (!default_encoding) goto bad; default_encoding_c = PyBytes_AsString(default_encoding); if (!default_encoding_c) goto bad; __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c)); if (!__PYX_DEFAULT_STRING_ENCODING) goto bad; strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c); Py_DECREF(default_encoding); return 0; bad: Py_XDECREF(default_encoding); return -1; } #endif #endif /* Test for GCC > 2.95 */ #if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95))) #define likely(x) __builtin_expect(!!(x), 1) #define unlikely(x) __builtin_expect(!!(x), 0) #else /* !__GNUC__ or GCC < 2.95 */ #define likely(x) (x) #define unlikely(x) (x) #endif /* __GNUC__ */ static PyObject *__pyx_m; static PyObject *__pyx_d; static PyObject *__pyx_b; static PyObject *__pyx_empty_tuple; static PyObject *__pyx_empty_bytes; static PyObject *__pyx_empty_unicode; static int __pyx_lineno; static int __pyx_clineno = 0; static const char * __pyx_cfilenm= __FILE__; static const char *__pyx_filename; static const char *__pyx_f[] = { "src/operations.pxi", "src/handlers.pxi", "src/misc.pxi", "src/fuse_api.pxi", "src/llfuse.pyx", "type.pxd", }; /*--- Type declarations ---*/ struct __pyx_obj_6llfuse_Lock; struct __pyx_obj_6llfuse_NoLockManager; struct __pyx_obj_6llfuse_RequestContext; struct __pyx_obj_6llfuse_SetattrFields; struct __pyx_obj_6llfuse_EntryAttributes; struct __pyx_obj_6llfuse_StatvfsData; struct __pyx_obj_6llfuse_FUSEError; struct __pyx_obj_6llfuse_NotifyRequest; struct __pyx_obj_6llfuse_VoidPtrCapsule; /* "signal.pxd":3 * # 7.14 Signal handling * * ctypedef void (*sighandler_t)(int SIGNUM) nogil # <<<<<<<<<<<<<< * * cdef extern from "" nogil: */ typedef void (*__pyx_t_4libc_6signal_sighandler_t)(int); struct __pyx_t_6llfuse_worker_data_t; typedef struct __pyx_t_6llfuse_worker_data_t __pyx_t_6llfuse_worker_data_t; /* "src/fuse_api.pxi":392 * fuse_session_process_buf(session, &buf, ch) * * ctypedef struct worker_data_t: # <<<<<<<<<<<<<< * sem_t* sem * int thread_no */ struct __pyx_t_6llfuse_worker_data_t { sem_t *sem; int thread_no; int started; pthread_t thread_id; void *buf; size_t bufsize; }; /* "src/misc.pxi":139 * raise * * cdef class Lock: # <<<<<<<<<<<<<< * ''' * This is the class of lock itself as well as a context manager to */ struct __pyx_obj_6llfuse_Lock { PyObject_HEAD }; /* "src/misc.pxi":242 * raise PicklingError("Lock instances can't be pickled") * * cdef class NoLockManager: # <<<<<<<<<<<<<< * '''Context manager to execute code while the global lock is released''' * */ struct __pyx_obj_6llfuse_NoLockManager { PyObject_HEAD }; /* "src/misc.pxi":317 * * @cython.freelist(10) * cdef class RequestContext: # <<<<<<<<<<<<<< * ''' * Instances of this class are passed to some `Operations` methods to */ struct __pyx_obj_6llfuse_RequestContext { PyObject_HEAD uid_t uid; pid_t pid; gid_t gid; mode_t umask; }; /* "src/misc.pxi":333 * * @cython.freelist(10) * cdef class SetattrFields: # <<<<<<<<<<<<<< * ''' * `SetattrFields` instances are passed to the `~Operations.setattr` handler */ struct __pyx_obj_6llfuse_SetattrFields { PyObject_HEAD PyObject *update_atime; PyObject *update_mtime; PyObject *update_mode; PyObject *update_uid; PyObject *update_gid; PyObject *update_size; }; /* "src/misc.pxi":358 * * @cython.freelist(30) * cdef class EntryAttributes: # <<<<<<<<<<<<<< * ''' * Instances of this class store attributes of directory entries. */ struct __pyx_obj_6llfuse_EntryAttributes { PyObject_HEAD struct fuse_entry_param fuse_param; struct stat *attr; }; /* "src/misc.pxi":538 * * @cython.freelist(1) * cdef class StatvfsData: # <<<<<<<<<<<<<< * ''' * Instances of this class store information about the file system. */ struct __pyx_obj_6llfuse_StatvfsData { PyObject_HEAD struct statvfs stat; }; /* "src/misc.pxi":628 * # As of Cython 0.23.1, @cython.freelist cannot be used for * # classes that derive from a builtin type. * cdef class FUSEError(Exception): # <<<<<<<<<<<<<< * ''' * This exception may be raised by request handlers to indicate that */ struct __pyx_obj_6llfuse_FUSEError { PyBaseExceptionObject __pyx_base; int errno_; }; /* "src/misc.pxi":653 * * @cython.freelist(300) * cdef class NotifyRequest: # <<<<<<<<<<<<<< * cdef fuse_ino_t ino * cdef char attr_only */ struct __pyx_obj_6llfuse_NotifyRequest { PyObject_HEAD fuse_ino_t ino; char attr_only; PyObject *name; int kind; }; /* "src/misc.pxi":684 * return buf * * cdef class VoidPtrCapsule: # <<<<<<<<<<<<<< * cdef void* ptr * */ struct __pyx_obj_6llfuse_VoidPtrCapsule { PyObject_HEAD void *ptr; }; /* --- Runtime support code (head) --- */ /* Refnanny.proto */ #ifndef CYTHON_REFNANNY #define CYTHON_REFNANNY 0 #endif #if CYTHON_REFNANNY typedef struct { void (*INCREF)(void*, PyObject*, int); void (*DECREF)(void*, PyObject*, int); void (*GOTREF)(void*, PyObject*, int); void (*GIVEREF)(void*, PyObject*, int); void* (*SetupContext)(const char*, int, const char*); void (*FinishContext)(void**); } __Pyx_RefNannyAPIStruct; static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL; static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname); #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL; #ifdef WITH_THREAD #define __Pyx_RefNannySetupContext(name, acquire_gil)\ if (acquire_gil) {\ PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\ __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\ PyGILState_Release(__pyx_gilstate_save);\ } else {\ __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\ } #else #define __Pyx_RefNannySetupContext(name, acquire_gil)\ __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__) #endif #define __Pyx_RefNannyFinishContext()\ __Pyx_RefNanny->FinishContext(&__pyx_refnanny) #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__) #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__) #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__) #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__) #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0) #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0) #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0) #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0) #else #define __Pyx_RefNannyDeclarations #define __Pyx_RefNannySetupContext(name, acquire_gil) #define __Pyx_RefNannyFinishContext() #define __Pyx_INCREF(r) Py_INCREF(r) #define __Pyx_DECREF(r) Py_DECREF(r) #define __Pyx_GOTREF(r) #define __Pyx_GIVEREF(r) #define __Pyx_XINCREF(r) Py_XINCREF(r) #define __Pyx_XDECREF(r) Py_XDECREF(r) #define __Pyx_XGOTREF(r) #define __Pyx_XGIVEREF(r) #endif #define __Pyx_XDECREF_SET(r, v) do {\ PyObject *tmp = (PyObject *) r;\ r = v; __Pyx_XDECREF(tmp);\ } while (0) #define __Pyx_DECREF_SET(r, v) do {\ PyObject *tmp = (PyObject *) r;\ r = v; __Pyx_DECREF(tmp);\ } while (0) #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0) #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0) /* PyObjectGetAttrStr.proto */ #if CYTHON_USE_TYPE_SLOTS static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) { PyTypeObject* tp = Py_TYPE(obj); if (likely(tp->tp_getattro)) return tp->tp_getattro(obj, attr_name); #if PY_MAJOR_VERSION < 3 if (likely(tp->tp_getattr)) return tp->tp_getattr(obj, PyString_AS_STRING(attr_name)); #endif return PyObject_GetAttr(obj, attr_name); } #else #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n) #endif /* GetBuiltinName.proto */ static PyObject *__Pyx_GetBuiltinName(PyObject *name); /* RaiseArgTupleInvalid.proto */ static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact, Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found); /* RaiseDoubleKeywords.proto */ static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name); /* ParseKeywords.proto */ static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\ PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\ const char* function_name); /* PyObjectCall.proto */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw); #else #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw) #endif /* PyThreadStateGet.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_PyThreadState_declare PyThreadState *__pyx_tstate; #define __Pyx_PyThreadState_assign __pyx_tstate = PyThreadState_GET(); #else #define __Pyx_PyThreadState_declare #define __Pyx_PyThreadState_assign #endif /* PyErrFetchRestore.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_ErrRestoreWithState(type, value, tb) __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb) #define __Pyx_ErrFetchWithState(type, value, tb) __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb) #define __Pyx_ErrRestore(type, value, tb) __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb) #define __Pyx_ErrFetch(type, value, tb) __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb) static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb); static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb); #else #define __Pyx_ErrRestoreWithState(type, value, tb) PyErr_Restore(type, value, tb) #define __Pyx_ErrFetchWithState(type, value, tb) PyErr_Fetch(type, value, tb) #define __Pyx_ErrRestore(type, value, tb) PyErr_Restore(type, value, tb) #define __Pyx_ErrFetch(type, value, tb) PyErr_Fetch(type, value, tb) #endif /* RaiseException.proto */ static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause); /* Import.proto */ static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level); /* IterFinish.proto */ static CYTHON_INLINE int __Pyx_IterFinish(void); /* PyFunctionFastCall.proto */ #if CYTHON_FAST_PYCALL #define __Pyx_PyFunction_FastCall(func, args, nargs)\ __Pyx_PyFunction_FastCallDict((func), (args), (nargs), NULL) #if 1 || PY_VERSION_HEX < 0x030600B1 static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, int nargs, PyObject *kwargs); #else #define __Pyx_PyFunction_FastCallDict(func, args, nargs, kwargs) _PyFunction_FastCallDict(func, args, nargs, kwargs) #endif #endif /* PyObjectCallMethO.proto */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg); #endif /* PyObjectCallNoArg.proto */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func); #else #define __Pyx_PyObject_CallNoArg(func) __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL) #endif /* PyCFunctionFastCall.proto */ #if CYTHON_FAST_PYCCALL static CYTHON_INLINE PyObject *__Pyx_PyCFunction_FastCall(PyObject *func, PyObject **args, Py_ssize_t nargs); #else #define __Pyx_PyCFunction_FastCall(func, args, nargs) (assert(0), NULL) #endif /* PyObjectCallOneArg.proto */ static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg); /* PyObjectCallMethod0.proto */ static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name); /* RaiseNeedMoreValuesToUnpack.proto */ static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index); /* RaiseTooManyValuesToUnpack.proto */ static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected); /* UnpackItemEndCheck.proto */ static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected); /* RaiseNoneIterError.proto */ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void); /* UnpackTupleError.proto */ static void __Pyx_UnpackTupleError(PyObject *, Py_ssize_t index); /* UnpackTuple2.proto */ static CYTHON_INLINE int __Pyx_unpack_tuple2(PyObject* tuple, PyObject** value1, PyObject** value2, int is_tuple, int has_known_size, int decref_tuple); /* dict_iter.proto */ static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* dict, int is_dict, PyObject* method_name, Py_ssize_t* p_orig_length, int* p_is_dict); static CYTHON_INLINE int __Pyx_dict_iter_next(PyObject* dict_or_iter, Py_ssize_t orig_length, Py_ssize_t* ppos, PyObject** pkey, PyObject** pvalue, PyObject** pitem, int is_dict); /* ListAppend.proto */ #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) { PyListObject* L = (PyListObject*) list; Py_ssize_t len = Py_SIZE(list); if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) { Py_INCREF(x); PyList_SET_ITEM(list, len, x); Py_SIZE(list) = len+1; return 0; } return PyList_Append(list, x); } #else #define __Pyx_PyList_Append(L,x) PyList_Append(L,x) #endif /* GetModuleGlobalName.proto */ static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name); /* ForceInitThreads.proto */ #ifndef __PYX_FORCE_INIT_THREADS #define __PYX_FORCE_INIT_THREADS 0 #endif /* PyObjectLookupSpecial.proto */ #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x02070000 static CYTHON_INLINE PyObject* __Pyx_PyObject_LookupSpecial(PyObject* obj, PyObject* attr_name) { PyObject *res; PyTypeObject *tp = Py_TYPE(obj); #if PY_MAJOR_VERSION < 3 if (unlikely(PyInstance_Check(obj))) return __Pyx_PyObject_GetAttrStr(obj, attr_name); #endif res = _PyType_Lookup(tp, attr_name); if (likely(res)) { descrgetfunc f = Py_TYPE(res)->tp_descr_get; if (!f) { Py_INCREF(res); } else { res = f(res, obj, (PyObject *)tp); } } else { PyErr_SetObject(PyExc_AttributeError, attr_name); } return res; } #else #define __Pyx_PyObject_LookupSpecial(o,n) __Pyx_PyObject_GetAttrStr(o,n) #endif /* SaveResetException.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_ExceptionSave(type, value, tb) __Pyx__ExceptionSave(__pyx_tstate, type, value, tb) static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb); #define __Pyx_ExceptionReset(type, value, tb) __Pyx__ExceptionReset(__pyx_tstate, type, value, tb) static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb); #else #define __Pyx_ExceptionSave(type, value, tb) PyErr_GetExcInfo(type, value, tb) #define __Pyx_ExceptionReset(type, value, tb) PyErr_SetExcInfo(type, value, tb) #endif /* GetException.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb) static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb); #else static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb); #endif /* WriteUnraisableException.proto */ static void __Pyx_WriteUnraisable(const char *name, int clineno, int lineno, const char *filename, int full_traceback, int nogil); /* ExtTypeTest.proto */ static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type); /* None.proto */ static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname); /* PyErrExceptionMatches.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err) static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err); #else #define __Pyx_PyErr_ExceptionMatches(err) PyErr_ExceptionMatches(err) #endif /* SwapException.proto */ #if CYTHON_FAST_THREAD_STATE #define __Pyx_ExceptionSwap(type, value, tb) __Pyx__ExceptionSwap(__pyx_tstate, type, value, tb) static CYTHON_INLINE void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb); #else static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb); #endif /* StringJoin.proto */ #if PY_MAJOR_VERSION < 3 #define __Pyx_PyString_Join __Pyx_PyBytes_Join #define __Pyx_PyBaseString_Join(s, v) (PyUnicode_CheckExact(s) ? PyUnicode_Join(s, v) : __Pyx_PyBytes_Join(s, v)) #else #define __Pyx_PyString_Join PyUnicode_Join #define __Pyx_PyBaseString_Join PyUnicode_Join #endif #if CYTHON_COMPILING_IN_CPYTHON #if PY_MAJOR_VERSION < 3 #define __Pyx_PyBytes_Join _PyString_Join #else #define __Pyx_PyBytes_Join _PyBytes_Join #endif #else static CYTHON_INLINE PyObject* __Pyx_PyBytes_Join(PyObject* sep, PyObject* values); #endif /* GetItemInt.proto */ #define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\ (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\ __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\ (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\ __Pyx_GetItemInt_Generic(o, to_py_func(i)))) #define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\ (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\ __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\ (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL)) static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i, int wraparound, int boundscheck); #define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\ (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\ __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\ (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL)) static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i, int wraparound, int boundscheck); static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j); static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list, int wraparound, int boundscheck); /* KeywordStringCheck.proto */ static CYTHON_INLINE int __Pyx_CheckKeywordStrings(PyObject *kwdict, const char* function_name, int kw_allowed); /* PyIntBinop.proto */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_TrueDivideObjC(PyObject *op1, PyObject *op2, long intval, int inplace); #else #define __Pyx_PyInt_TrueDivideObjC(op1, op2, intval, inplace)\ (inplace ? PyNumber_InPlaceTrueDivide(op1, op2) : PyNumber_TrueDivide(op1, op2)) #endif /* PyIntBinop.proto */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_RemainderObjC(PyObject *op1, PyObject *op2, long intval, int inplace); #else #define __Pyx_PyInt_RemainderObjC(op1, op2, intval, inplace)\ (inplace ? PyNumber_InPlaceRemainder(op1, op2) : PyNumber_Remainder(op1, op2)) #endif /* GetAttr.proto */ static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *); /* ArgTypeTest.proto */ static CYTHON_INLINE int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, const char *name, int exact); /* IncludeStringH.proto */ #include /* BytesEquals.proto */ static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals); /* UnicodeEquals.proto */ static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals); /* PyIntBinop.proto */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, long intval, int inplace); #else #define __Pyx_PyInt_EqObjC(op1, op2, intval, inplace)\ PyObject_RichCompare(op1, op2, Py_EQ) #endif /* FetchCommonType.proto */ static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type); /* CythonFunction.proto */ #define __Pyx_CyFunction_USED 1 #include #define __Pyx_CYFUNCTION_STATICMETHOD 0x01 #define __Pyx_CYFUNCTION_CLASSMETHOD 0x02 #define __Pyx_CYFUNCTION_CCLASS 0x04 #define __Pyx_CyFunction_GetClosure(f)\ (((__pyx_CyFunctionObject *) (f))->func_closure) #define __Pyx_CyFunction_GetClassObj(f)\ (((__pyx_CyFunctionObject *) (f))->func_classobj) #define __Pyx_CyFunction_Defaults(type, f)\ ((type *)(((__pyx_CyFunctionObject *) (f))->defaults)) #define __Pyx_CyFunction_SetDefaultsGetter(f, g)\ ((__pyx_CyFunctionObject *) (f))->defaults_getter = (g) typedef struct { PyCFunctionObject func; #if PY_VERSION_HEX < 0x030500A0 PyObject *func_weakreflist; #endif PyObject *func_dict; PyObject *func_name; PyObject *func_qualname; PyObject *func_doc; PyObject *func_globals; PyObject *func_code; PyObject *func_closure; PyObject *func_classobj; void *defaults; int defaults_pyobjects; int flags; PyObject *defaults_tuple; PyObject *defaults_kwdict; PyObject *(*defaults_getter)(PyObject *); PyObject *func_annotations; } __pyx_CyFunctionObject; static PyTypeObject *__pyx_CyFunctionType = 0; #define __Pyx_CyFunction_NewEx(ml, flags, qualname, self, module, globals, code)\ __Pyx_CyFunction_New(__pyx_CyFunctionType, ml, flags, qualname, self, module, globals, code) static PyObject *__Pyx_CyFunction_New(PyTypeObject *, PyMethodDef *ml, int flags, PyObject* qualname, PyObject *self, PyObject *module, PyObject *globals, PyObject* code); static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *m, size_t size, int pyobjects); static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *m, PyObject *tuple); static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *m, PyObject *dict); static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *m, PyObject *dict); static int __pyx_CyFunction_init(void); /* PyObjectSetAttrStr.proto */ #if CYTHON_USE_TYPE_SLOTS #define __Pyx_PyObject_DelAttrStr(o,n) __Pyx_PyObject_SetAttrStr(o,n,NULL) static CYTHON_INLINE int __Pyx_PyObject_SetAttrStr(PyObject* obj, PyObject* attr_name, PyObject* value) { PyTypeObject* tp = Py_TYPE(obj); if (likely(tp->tp_setattro)) return tp->tp_setattro(obj, attr_name, value); #if PY_MAJOR_VERSION < 3 if (likely(tp->tp_setattr)) return tp->tp_setattr(obj, PyString_AS_STRING(attr_name), value); #endif return PyObject_SetAttr(obj, attr_name, value); } #else #define __Pyx_PyObject_DelAttrStr(o,n) PyObject_DelAttr(o,n) #define __Pyx_PyObject_SetAttrStr(o,n,v) PyObject_SetAttr(o,n,v) #endif /* SliceObject.proto */ static CYTHON_INLINE PyObject* __Pyx_PyObject_GetSlice( PyObject* obj, Py_ssize_t cstart, Py_ssize_t cstop, PyObject** py_start, PyObject** py_stop, PyObject** py_slice, int has_cstart, int has_cstop, int wraparound); /* ImportFrom.proto */ static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name); /* decode_c_string.proto */ static CYTHON_INLINE PyObject* __Pyx_decode_c_string( const char* cstring, Py_ssize_t start, Py_ssize_t stop, const char* encoding, const char* errors, PyObject* (*decode_func)(const char *s, Py_ssize_t size, const char *errors)); /* Globals.proto */ static PyObject* __Pyx_Globals(void); /* CalculateMetaclass.proto */ static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases); /* Py3ClassCreate.proto */ static PyObject *__Pyx_Py3MetaclassPrepare(PyObject *metaclass, PyObject *bases, PyObject *name, PyObject *qualname, PyObject *mkw, PyObject *modname, PyObject *doc); static PyObject *__Pyx_Py3ClassCreate(PyObject *metaclass, PyObject *name, PyObject *bases, PyObject *dict, PyObject *mkw, int calculate_metaclass, int allow_py2_metaclass); /* pyfrozenset_new.proto */ static CYTHON_INLINE PyObject* __Pyx_PyFrozenSet_New(PyObject* it) { if (it) { PyObject* result; #if CYTHON_COMPILING_IN_PYPY PyObject* args; args = PyTuple_Pack(1, it); if (unlikely(!args)) return NULL; result = PyObject_Call((PyObject*)&PyFrozenSet_Type, args, NULL); Py_DECREF(args); return result; #else if (PyFrozenSet_CheckExact(it)) { Py_INCREF(it); return it; } result = PyFrozenSet_New(it); if (unlikely(!result)) return NULL; if (likely(PySet_GET_SIZE(result))) return result; Py_DECREF(result); #endif } #if CYTHON_USE_TYPE_SLOTS return PyFrozenSet_Type.tp_new(&PyFrozenSet_Type, __pyx_empty_tuple, NULL); #else return PyObject_Call((PyObject*)&PyFrozenSet_Type, __pyx_empty_tuple, NULL); #endif } /* CodeObjectCache.proto */ typedef struct { PyCodeObject* code_object; int code_line; } __Pyx_CodeObjectCacheEntry; struct __Pyx_CodeObjectCache { int count; int max_count; __Pyx_CodeObjectCacheEntry* entries; }; static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL}; static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line); static PyCodeObject *__pyx_find_code_object(int code_line); static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object); /* AddTraceback.proto */ static void __Pyx_AddTraceback(const char *funcname, int c_line, int py_line, const char *filename); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fuse_ino_t(fuse_ino_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_unsigned_long(unsigned long value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uint64_t(uint64_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_mode_t(mode_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_dev_t(dev_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_off_t(off_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uint32_t(uint32_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uid_t(uid_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_pid_t(pid_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_gid_t(gid_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_nlink_t(nlink_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_blkcnt_t(blkcnt_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_blksize_t(blksize_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_time_t(time_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fsblkcnt_t(fsblkcnt_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fsfilcnt_t(fsfilcnt_t value); /* CIntToPy.proto */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_pthread_t(pthread_t value); /* CIntFromPy.proto */ static CYTHON_INLINE size_t __Pyx_PyInt_As_size_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE fuse_ino_t __Pyx_PyInt_As_fuse_ino_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE uint64_t __Pyx_PyInt_As_uint64_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE off_t __Pyx_PyInt_As_off_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE ino_t __Pyx_PyInt_As_ino_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE unsigned long __Pyx_PyInt_As_unsigned_long(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE mode_t __Pyx_PyInt_As_mode_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE nlink_t __Pyx_PyInt_As_nlink_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE uid_t __Pyx_PyInt_As_uid_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE gid_t __Pyx_PyInt_As_gid_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE dev_t __Pyx_PyInt_As_dev_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE blkcnt_t __Pyx_PyInt_As_blkcnt_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE blksize_t __Pyx_PyInt_As_blksize_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE time_t __Pyx_PyInt_As_time_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE fsblkcnt_t __Pyx_PyInt_As_fsblkcnt_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE fsfilcnt_t __Pyx_PyInt_As_fsfilcnt_t(PyObject *); /* CIntFromPy.proto */ static CYTHON_INLINE char __Pyx_PyInt_As_char(PyObject *); /* CheckBinaryVersion.proto */ static int __Pyx_check_binary_version(void); /* PyIdentifierFromString.proto */ #if !defined(__Pyx_PyIdentifier_FromString) #if PY_MAJOR_VERSION < 3 #define __Pyx_PyIdentifier_FromString(s) PyString_FromString(s) #else #define __Pyx_PyIdentifier_FromString(s) PyUnicode_FromString(s) #endif #endif /* ModuleImport.proto */ static PyObject *__Pyx_ImportModule(const char *name); /* TypeImport.proto */ static PyTypeObject *__Pyx_ImportType(const char *module_name, const char *class_name, size_t size, int strict); /* InitStrings.proto */ static int __Pyx_InitStrings(__Pyx_StringTabEntry *t); /* Module declarations from 'fuse_opt' */ /* Module declarations from 'posix.types' */ /* Module declarations from 'libc.stdint' */ /* Module declarations from 'fuse_common' */ /* Module declarations from 'posix.stat' */ /* Module declarations from 'libc.sys.statvfs' */ /* Module declarations from 'libc.string' */ /* Module declarations from 'libc.stdlib' */ /* Module declarations from 'fuse_lowlevel' */ /* Module declarations from 'posix.signal' */ /* Module declarations from 'pthread' */ /* Module declarations from 'libc' */ /* Module declarations from 'libc.errno' */ /* Module declarations from 'libc.dirent' */ /* Module declarations from 'posix.unistd' */ /* Module declarations from 'posix.time' */ /* Module declarations from 'libc.stdio' */ /* Module declarations from '__builtin__' */ /* Module declarations from 'cpython.type' */ static PyTypeObject *__pyx_ptype_7cpython_4type_type = 0; /* Module declarations from 'cpython.exc' */ /* Module declarations from 'cpython' */ /* Module declarations from 'cpython.object' */ /* Module declarations from 'cpython.bytes' */ /* Module declarations from 'cpython.buffer' */ /* Module declarations from 'cython' */ /* Module declarations from 'cpython.version' */ /* Module declarations from 'libc.signal' */ /* Module declarations from 'llfuse' */ static PyTypeObject *__pyx_ptype_6llfuse_Lock = 0; static PyTypeObject *__pyx_ptype_6llfuse_NoLockManager = 0; static PyTypeObject *__pyx_ptype_6llfuse_RequestContext = 0; static PyTypeObject *__pyx_ptype_6llfuse_SetattrFields = 0; static PyTypeObject *__pyx_ptype_6llfuse_EntryAttributes = 0; static PyTypeObject *__pyx_ptype_6llfuse_StatvfsData = 0; static PyTypeObject *__pyx_ptype_6llfuse_FUSEError = 0; static PyTypeObject *__pyx_ptype_6llfuse_NotifyRequest = 0; static PyTypeObject *__pyx_ptype_6llfuse_VoidPtrCapsule = 0; static PyObject *__pyx_v_6llfuse_operations = 0; static PyObject *__pyx_v_6llfuse_mountpoint_b = 0; static struct fuse_session *__pyx_v_6llfuse_session; static struct fuse_chan *__pyx_v_6llfuse_channel; static struct fuse_lowlevel_ops __pyx_v_6llfuse_fuse_ops; static PyObject *__pyx_v_6llfuse_exc_info = 0; static int __pyx_v_6llfuse_exit_reason; static pthread_mutex_t __pyx_v_6llfuse_exc_info_mutex; static PyObject *__pyx_v_6llfuse__notify_queue = 0; static struct sigaction __pyx_v_6llfuse_sa_backup[5]; static void __pyx_f_6llfuse_fuse_init(void *, struct fuse_conn_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_destroy(void *); /*proto*/ static void __pyx_f_6llfuse_fuse_lookup(fuse_req_t, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_forget(fuse_req_t, fuse_ino_t, unsigned long); /*proto*/ static void __pyx_f_6llfuse_fuse_forget_multi(fuse_req_t, size_t, struct fuse_forget_data *); /*proto*/ static void __pyx_f_6llfuse_fuse_getattr(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_setattr(fuse_req_t, fuse_ino_t, struct stat *, int, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_readlink(fuse_req_t, fuse_ino_t); /*proto*/ static void __pyx_f_6llfuse_fuse_mknod(fuse_req_t, fuse_ino_t, const char *, mode_t, dev_t); /*proto*/ static void __pyx_f_6llfuse_fuse_mkdir(fuse_req_t, fuse_ino_t, const char *, mode_t); /*proto*/ static void __pyx_f_6llfuse_fuse_unlink(fuse_req_t, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_rmdir(fuse_req_t, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_symlink(fuse_req_t, const char *, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_rename(fuse_req_t, fuse_ino_t, const char *, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_link(fuse_req_t, fuse_ino_t, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_open(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_read(fuse_req_t, fuse_ino_t, size_t, off_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_write(fuse_req_t, fuse_ino_t, const char *, size_t, off_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_write_buf(fuse_req_t, fuse_ino_t, struct fuse_bufvec *, off_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_flush(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_release(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_fsync(fuse_req_t, fuse_ino_t, int, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_opendir(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_readdir(fuse_req_t, fuse_ino_t, size_t, off_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_releasedir(fuse_req_t, fuse_ino_t, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_fsyncdir(fuse_req_t, fuse_ino_t, int, struct fuse_file_info *); /*proto*/ static void __pyx_f_6llfuse_fuse_statfs(fuse_req_t, fuse_ino_t); /*proto*/ static void __pyx_f_6llfuse_fuse_setxattr_darwin(fuse_req_t, fuse_ino_t, const char *, const char *, size_t, int, uint32_t); /*proto*/ static void __pyx_f_6llfuse_fuse_setxattr(fuse_req_t, fuse_ino_t, const char *, const char *, size_t, int); /*proto*/ static void __pyx_f_6llfuse_fuse_getxattr_darwin(fuse_req_t, fuse_ino_t, const char *, size_t, uint32_t); /*proto*/ static void __pyx_f_6llfuse_fuse_getxattr(fuse_req_t, fuse_ino_t, const char *, size_t); /*proto*/ static void __pyx_f_6llfuse_fuse_listxattr(fuse_req_t, fuse_ino_t, size_t); /*proto*/ static void __pyx_f_6llfuse_fuse_removexattr(fuse_req_t, fuse_ino_t, const char *); /*proto*/ static void __pyx_f_6llfuse_fuse_access(fuse_req_t, fuse_ino_t, int); /*proto*/ static void __pyx_f_6llfuse_fuse_create(fuse_req_t, fuse_ino_t, const char *, mode_t, struct fuse_file_info *); /*proto*/ static int __pyx_f_6llfuse_handle_exc(fuse_req_t); /*proto*/ static PyObject *__pyx_f_6llfuse_get_request_context(fuse_req_t); /*proto*/ static void __pyx_f_6llfuse_init_fuse_ops(void); /*proto*/ static PyObject *__pyx_f_6llfuse_make_fuse_args(PyObject *, struct fuse_args *); /*proto*/ static PyObject *__pyx_f_6llfuse_str2bytes(PyObject *); /*proto*/ static PyObject *__pyx_f_6llfuse_bytes2str(PyObject *); /*proto*/ static PyObject *__pyx_f_6llfuse_strerror(int); /*proto*/ static PyObject *__pyx_f_6llfuse_PyBytes_from_bufvec(struct fuse_bufvec *); /*proto*/ static void __pyx_f_6llfuse_signal_handler(int, siginfo_t *, void *); /*proto*/ static void __pyx_f_6llfuse_do_nothing(int, siginfo_t *, void *); /*proto*/ static int __pyx_f_6llfuse_sigaction_p(int, struct sigaction *, struct sigaction *); /*proto*/ static PyObject *__pyx_f_6llfuse_set_signal_handlers(void); /*proto*/ static PyObject *__pyx_f_6llfuse_restore_signal_handlers(void); /*proto*/ static void *__pyx_f_6llfuse_calloc_or_raise(size_t, size_t); /*proto*/ static PyObject *__pyx_f_6llfuse_session_loop_single(void); /*proto*/ static PyObject *__pyx_f_6llfuse_session_loop(void *, size_t); /*proto*/ static void *__pyx_f_6llfuse_worker_start(void *); /*proto*/ static PyObject *__pyx_f_6llfuse_session_loop_mt(PyObject *); /*proto*/ #define __Pyx_MODULE_NAME "llfuse" int __pyx_module_is_main_llfuse = 0; /* Implementation of 'llfuse' */ static PyObject *__pyx_builtin_object; static PyObject *__pyx_builtin_range; static PyObject *__pyx_builtin_OverflowError; static PyObject *__pyx_builtin_ValueError; static PyObject *__pyx_builtin_enumerate; static PyObject *__pyx_builtin_TypeError; static PyObject *__pyx_builtin_RuntimeError; static PyObject *__pyx_builtin_OSError; static PyObject *__pyx_builtin_MemoryError; static PyObject *__pyx_builtin_open; static const char __pyx_k_[] = "\n"; static const char __pyx_k_o[] = "-o"; static const char __pyx_k_r[] = "r"; static const char __pyx_k_s[] = " %s"; static const char __pyx_k_t[] = "t"; static const char __pyx_k_x[] = "x"; static const char __pyx_k_fh[] = "fh"; static const char __pyx_k_os[] = "os"; static const char __pyx_k__35[] = "\000"; static const char __pyx_k_buf[] = "buf"; static const char __pyx_k_ctx[] = "ctx"; static const char __pyx_k_doc[] = "__doc__"; static const char __pyx_k_fse[] = "fse"; static const char __pyx_k_get[] = "get"; static const char __pyx_k_ino[] = "ino"; static const char __pyx_k_len[] = "len_"; static const char __pyx_k_log[] = "log"; static const char __pyx_k_off[] = "off"; static const char __pyx_k_ops[] = "ops"; static const char __pyx_k_pid[] = "pid"; static const char __pyx_k_put[] = "put"; static const char __pyx_k_req[] = "req"; static const char __pyx_k_res[] = "res"; static const char __pyx_k_ret[] = "ret"; static const char __pyx_k_sys[] = "sys"; static const char __pyx_k_tmp[] = "tmp"; static const char __pyx_k_attr[] = "attr"; static const char __pyx_k_code[] = "code"; static const char __pyx_k_data[] = "data"; static const char __pyx_k_dirp[] = "dirp"; static const char __pyx_k_exit[] = "__exit__"; static const char __pyx_k_gids[] = "gids"; static const char __pyx_k_info[] = "info"; static const char __pyx_k_init[] = "init"; static const char __pyx_k_join[] = "join"; static const char __pyx_k_line[] = "line"; static const char __pyx_k_link[] = "link"; static const char __pyx_k_lock[] = "lock"; static const char __pyx_k_main[] = "__main__"; static const char __pyx_k_mode[] = "mode"; static const char __pyx_k_name[] = "name"; static const char __pyx_k_open[] = "open"; static const char __pyx_k_path[] = "path"; static const char __pyx_k_rdev[] = "rdev"; static const char __pyx_k_read[] = "read"; static const char __pyx_k_self[] = "self"; static const char __pyx_k_size[] = "size"; static const char __pyx_k_test[] = "__test__"; static const char __pyx_k_user[] = "user"; static const char __pyx_k_Queue[] = "Queue"; static const char __pyx_k_block[] = "block"; static const char __pyx_k_close[] = "close"; static const char __pyx_k_cname[] = "cname"; static const char __pyx_k_count[] = "count"; static const char __pyx_k_cpath[] = "cpath"; static const char __pyx_k_debug[] = "debug"; static const char __pyx_k_enter[] = "__enter__"; static const char __pyx_k_errno[] = "errno"; static const char __pyx_k_error[] = "error"; static const char __pyx_k_flags[] = "flags"; static const char __pyx_k_flush[] = "flush"; static const char __pyx_k_frame[] = "frame"; static const char __pyx_k_fsync[] = "fsync"; static const char __pyx_k_inode[] = "inode"; static const char __pyx_k_items[] = "items"; static const char __pyx_k_mkdir[] = "mkdir"; static const char __pyx_k_mknod[] = "mknod"; static const char __pyx_k_names[] = "names"; static const char __pyx_k_pybuf[] = "pybuf"; static const char __pyx_k_queue[] = "queue"; static const char __pyx_k_range[] = "range"; static const char __pyx_k_rmdir[] = "rmdir"; static const char __pyx_k_split[] = "split"; static const char __pyx_k_start[] = "start"; static const char __pyx_k_str_t[] = "str_t"; static const char __pyx_k_strip[] = "strip"; static const char __pyx_k_uname[] = "uname"; static const char __pyx_k_value[] = "value"; static const char __pyx_k_write[] = "write"; static const char __pyx_k_Darwin[] = "Darwin"; static const char __pyx_k_Groups[] = "Groups:"; static const char __pyx_k_Thread[] = "Thread"; static const char __pyx_k_access[] = "access"; static const char __pyx_k_bufvec[] = "bufvec"; static const char __pyx_k_create[] = "create"; static const char __pyx_k_cvalue[] = "cvalue"; static const char __pyx_k_daemon[] = "daemon"; static const char __pyx_k_decode[] = "decode"; static const char __pyx_k_encode[] = "encode"; static const char __pyx_k_exc_tb[] = "exc_tb"; static const char __pyx_k_f_args[] = "f_args"; static const char __pyx_k_fields[] = "fields"; static const char __pyx_k_forget[] = "forget"; static const char __pyx_k_import[] = "__import__"; static const char __pyx_k_lineno[] = "lineno"; static const char __pyx_k_llfuse[] = "llfuse"; static const char __pyx_k_lookup[] = "lookup"; static const char __pyx_k_main_2[] = "main"; static const char __pyx_k_module[] = "__module__"; static const char __pyx_k_name_b[] = "name_b"; static const char __pyx_k_object[] = "object"; static const char __pyx_k_offset[] = "offset"; static const char __pyx_k_path_b[] = "path_b"; static const char __pyx_k_pickle[] = "pickle"; static const char __pyx_k_rename[] = "rename"; static const char __pyx_k_st_gid[] = "st_gid"; static const char __pyx_k_st_ino[] = "st_ino"; static const char __pyx_k_st_uid[] = "st_uid"; static const char __pyx_k_statfs[] = "statfs"; static const char __pyx_k_system[] = "system"; static const char __pyx_k_target[] = "target"; static const char __pyx_k_unlink[] = "unlink"; static const char __pyx_k_ENOATTR[] = "ENOATTR"; static const char __pyx_k_OSError[] = "OSError"; static const char __pyx_k_abspath[] = "abspath"; static const char __pyx_k_acquire[] = "acquire"; static const char __pyx_k_bufsize[] = "bufsize"; static const char __pyx_k_destroy[] = "destroy"; static const char __pyx_k_errno_d[] = "errno: %d"; static const char __pyx_k_exc_val[] = "exc_val"; static const char __pyx_k_f_bfree[] = "f_bfree"; static const char __pyx_k_f_bsize[] = "f_bsize"; static const char __pyx_k_f_ffree[] = "f_ffree"; static const char __pyx_k_f_files[] = "f_files"; static const char __pyx_k_getattr[] = "getattr"; static const char __pyx_k_inode_p[] = "inode_p"; static const char __pyx_k_listdir[] = "listdir"; static const char __pyx_k_logging[] = "logging"; static const char __pyx_k_maxsize[] = "maxsize"; static const char __pyx_k_on_exit[] = "on_exit"; static const char __pyx_k_opendir[] = "opendir"; static const char __pyx_k_options[] = "options"; static const char __pyx_k_os_path[] = "os.path"; static const char __pyx_k_prepare[] = "__prepare__"; static const char __pyx_k_readdir[] = "readdir"; static const char __pyx_k_release[] = "release"; static const char __pyx_k_setattr[] = "setattr"; static const char __pyx_k_st_mode[] = "st_mode"; static const char __pyx_k_st_rdev[] = "st_rdev"; static const char __pyx_k_st_size[] = "st_size"; static const char __pyx_k_symlink[] = "symlink"; static const char __pyx_k_timeout[] = "timeout"; static const char __pyx_k_unmount[] = "unmount"; static const char __pyx_k_version[] = "__version__"; static const char __pyx_k_workers[] = "workers"; static const char __pyx_k_basename[] = "basename"; static const char __pyx_k_callback[] = "callback"; static const char __pyx_k_datasync[] = "datasync"; static const char __pyx_k_exc_info[] = "exc_info"; static const char __pyx_k_exc_type[] = "exc_type"; static const char __pyx_k_f_bavail[] = "f_bavail"; static const char __pyx_k_f_blocks[] = "f_blocks"; static const char __pyx_k_f_favail[] = "f_favail"; static const char __pyx_k_f_frsize[] = "f_frsize"; static const char __pyx_k_filename[] = "filename"; static const char __pyx_k_fsyncdir[] = "fsyncdir"; static const char __pyx_k_getxattr[] = "getxattr"; static const char __pyx_k_name_new[] = "name_new"; static const char __pyx_k_name_old[] = "name_old"; static const char __pyx_k_new_name[] = "new_name"; static const char __pyx_k_nonempty[] = "nonempty"; static const char __pyx_k_qualname[] = "__qualname__"; static const char __pyx_k_readlink[] = "readlink"; static const char __pyx_k_s_d_in_s[] = "%s:%d, in %s"; static const char __pyx_k_setxattr[] = "setxattr"; static const char __pyx_k_st_nlink[] = "st_nlink"; static const char __pyx_k_strerror[] = "strerror"; static const char __pyx_k_threadId[] = "threadId"; static const char __pyx_k_us_ascii[] = "us-ascii"; static const char __pyx_k_ExitStack[] = "ExitStack"; static const char __pyx_k_TypeError[] = "TypeError"; static const char __pyx_k_attr_only[] = "attr_only"; static const char __pyx_k_enumerate[] = "enumerate"; static const char __pyx_k_exception[] = "exception"; static const char __pyx_k_f_namemax[] = "f_namemax"; static const char __pyx_k_getLogger[] = "getLogger"; static const char __pyx_k_listxattr[] = "listxattr"; static const char __pyx_k_metaclass[] = "__metaclass__"; static const char __pyx_k_namespace[] = "namespace"; static const char __pyx_k_st_blocks[] = "st_blocks"; static const char __pyx_k_threading[] = "threading"; static const char __pyx_k_traceback[] = "traceback"; static const char __pyx_k_Operations[] = "Operations"; static const char __pyx_k_ROOT_INODE[] = "ROOT_INODE"; static const char __pyx_k_ThreadID_s[] = "\n# ThreadID: %s"; static const char __pyx_k_ValueError[] = "ValueError"; static const char __pyx_k_big_writes[] = "big_writes"; static const char __pyx_k_cnamespace[] = "cnamespace"; static const char __pyx_k_contextlib[] = "contextlib"; static const char __pyx_k_generation[] = "generation"; static const char __pyx_k_inode_list[] = "inode_list"; static const char __pyx_k_mountpoint[] = "mountpoint"; static const char __pyx_k_releasedir[] = "releasedir"; static const char __pyx_k_size_guess[] = "size_guess"; static const char __pyx_k_st_blksize[] = "st_blksize"; static const char __pyx_k_stacktrace[] = "stacktrace"; static const char __pyx_k_startswith[] = "startswith"; static const char __pyx_k_MemoryError[] = "MemoryError"; static const char __pyx_k_contextlib2[] = "contextlib2"; static const char __pyx_k_notify_loop[] = "_notify_loop"; static const char __pyx_k_removexattr[] = "removexattr"; static const char __pyx_k_splice_move[] = "splice_move"; static const char __pyx_k_st_atime_ns[] = "st_atime_ns"; static const char __pyx_k_st_ctime_ns[] = "st_ctime_ns"; static const char __pyx_k_st_mtime_ns[] = "st_mtime_ns"; static const char __pyx_k_RuntimeError[] = "RuntimeError"; static const char __pyx_k_attr_timeout[] = "attr_timeout"; static const char __pyx_k_notify_store[] = "notify_store"; static const char __pyx_k_parent_inode[] = "parent_inode"; static const char __pyx_k_splice_write[] = "splice_write"; static const char __pyx_k_OverflowError[] = "OverflowError"; static const char __pyx_k_PicklingError[] = "PicklingError"; static const char __pyx_k_Python_LLFUSE[] = "Python-LLFUSE"; static const char __pyx_k_entry_timeout[] = "entry_timeout"; static const char __pyx_k_extract_stack[] = "extract_stack"; static const char __pyx_k_fuse_worker_d[] = "fuse-worker-%d"; static const char __pyx_k_lock_released[] = "lock_released"; static const char __pyx_k_proc_d_status[] = "/proc/%d/status"; static const char __pyx_k_current_frames[] = "_current_frames"; static const char __pyx_k_current_thread[] = "current_thread"; static const char __pyx_k_get_ino_t_bits[] = "get_ino_t_bits"; static const char __pyx_k_get_off_t_bits[] = "get_off_t_bits"; static const char __pyx_k_get_sup_groups[] = "get_sup_groups"; static const char __pyx_k_no_splice_read[] = "no_splice_read"; static const char __pyx_k_with_traceback[] = "with_traceback"; static const char __pyx_k_Operations_init[] = "Operations.init"; static const char __pyx_k_Operations_link[] = "Operations.link"; static const char __pyx_k_Operations_open[] = "Operations.open"; static const char __pyx_k_Operations_read[] = "Operations.read"; static const char __pyx_k_default_options[] = "default_options"; static const char __pyx_k_st_birthtime_ns[] = "st_birthtime_ns"; static const char __pyx_k_surrogateescape[] = "surrogateescape"; static const char __pyx_k_Operations_flush[] = "Operations.flush"; static const char __pyx_k_Operations_fsync[] = "Operations.fsync"; static const char __pyx_k_Operations_mkdir[] = "Operations.mkdir"; static const char __pyx_k_Operations_mknod[] = "Operations.mknod"; static const char __pyx_k_Operations_rmdir[] = "Operations.rmdir"; static const char __pyx_k_Operations_write[] = "Operations.write"; static const char __pyx_k_invalidate_entry[] = "invalidate_entry"; static const char __pyx_k_invalidate_inode[] = "invalidate_inode"; static const char __pyx_k_new_parent_inode[] = "new_parent_inode"; static const char __pyx_k_parent_inode_new[] = "parent_inode_new"; static const char __pyx_k_parent_inode_old[] = "parent_inode_old"; static const char __pyx_k_unknown_flag_s_o[] = "unknown flag(s): %o"; static const char __pyx_k_Operations_access[] = "Operations.access"; static const char __pyx_k_Operations_create[] = "Operations.create"; static const char __pyx_k_Operations_forget[] = "Operations.forget"; static const char __pyx_k_Operations_lookup[] = "Operations.lookup"; static const char __pyx_k_Operations_rename[] = "Operations.rename"; static const char __pyx_k_Operations_statfs[] = "Operations.statfs"; static const char __pyx_k_Operations_unlink[] = "Operations.unlink"; static const char __pyx_k_Unable_to_parse_s[] = "Unable to parse %s"; static const char __pyx_k_fuse_mount_failed[] = "fuse_mount failed"; static const char __pyx_k_Calling_fuse_mount[] = "Calling fuse_mount"; static const char __pyx_k_Operations_destroy[] = "Operations.destroy"; static const char __pyx_k_Operations_getattr[] = "Operations.getattr"; static const char __pyx_k_Operations_opendir[] = "Operations.opendir"; static const char __pyx_k_Operations_readdir[] = "Operations.readdir"; static const char __pyx_k_Operations_release[] = "Operations.release"; static const char __pyx_k_Operations_setattr[] = "Operations.setattr"; static const char __pyx_k_Operations_symlink[] = "Operations.symlink"; static const char __pyx_k_main_locals_lambda[] = "main.."; static const char __pyx_k_Initializing_llfuse[] = "Initializing llfuse"; static const char __pyx_k_Operations_fsyncdir[] = "Operations.fsyncdir"; static const char __pyx_k_Operations_getxattr[] = "Operations.getxattr"; static const char __pyx_k_Operations_readlink[] = "Operations.readlink"; static const char __pyx_k_Operations_setxattr[] = "Operations.setxattr"; static const char __pyx_k_default_permissions[] = "default_permissions"; static const char __pyx_k_Calling_fuse_unmount[] = "Calling fuse_unmount"; static const char __pyx_k_Exception_after_kill[] = "Exception after kill:"; static const char __pyx_k_Lock_not_initialized[] = "Lock not initialized"; static const char __pyx_k_Operations_listxattr[] = "Operations.listxattr"; static const char __pyx_k_sem_init_failed_with[] = "sem_init failed with "; static const char __pyx_k_Operations_releasedir[] = "Operations.releasedir"; static const char __pyx_k_Operations_stacktrace[] = "Operations.stacktrace"; static const char __pyx_k_getfilesystemencoding[] = "getfilesystemencoding"; static const char __pyx_k_sigaction_failed_with[] = "sigaction failed with "; static const char __pyx_k_Operations_removexattr[] = "Operations.removexattr"; static const char __pyx_k_fuse_lowlevel_new_failed[] = "fuse_lowlevel_new() failed"; static const char __pyx_k_Calling_fuse_lowlevel_new[] = "Calling fuse_lowlevel_new"; static const char __pyx_k_Calling_fuse_session_loop[] = "Calling fuse_session_loop"; static const char __pyx_k_fuse_buf_copy_failed_with[] = "fuse_buf_copy failed with "; static const char __pyx_k_pthread_create_failed_with[] = "pthread_create failed with "; static const char __pyx_k_pthread_join_failed_with_s[] = "pthread_join failed with: %s"; static const char __pyx_k_pthread_kill_failed_with_s[] = "pthread_kill failed with: %s"; static const char __pyx_k_Calling_fuse_session_destroy[] = "Calling fuse_session_destroy"; static const char __pyx_k_Calling_fuse_session_add_chan[] = "Calling fuse_session_add_chan"; static const char __pyx_k_Need_to_call_init_before_main[] = "Need to call init() before main()"; static const char __pyx_k_No_workers_is_not_a_good_idea[] = "No workers is not a good idea"; static const char __pyx_k_Other_thread_didn_t_take_lock[] = "Other thread didn't take lock"; static const char __pyx_k_Weird_request_kind_received_d[] = "Weird request kind received: %d"; static const char __pyx_k_This_class_defines_the_general[] = "\n This class defines the general and request handler methods that an\n Python-LLFUSE file system may implement. If a particular request handler has\n not been implemented, it must raise `FUSEError` with an errorcode of\n `errno.ENOSYS`. Further requests of this type will then be handled directly\n by the FUSE kernel module without calling the handler again.\n\n The only exception that request handlers are allowed to raise is\n `FUSEError`. This will cause the specified errno to be returned by the\n syscall that is being handled.\n\n It is recommended that file systems are derived from this class and only\n overwrite the handlers that they actually implement. (The methods defined in\n this class all just raise ``FUSEError(ENOSYS)`` or do nothing).\n "; static const char __pyx_k_FUSE_worker_thread_d_terminated[] = "FUSE worker thread %d terminated with exception, aborting processing"; static const char __pyx_k_Lock_instances_can_t_be_pickled[] = "Lock instances can't be pickled"; static const char __pyx_k_You_should_not_instantiate_this[] = "You should not instantiate this class, use the provided instance instead."; static const char __pyx_k_fuse_getattr_fuse_reply__failed[] = "fuse_getattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_getxattr_non_zero_position[] = "fuse_getxattr(): non-zero position (%d) not supported"; static const char __pyx_k_fuse_opendir_fuse_reply__failed[] = "fuse_opendir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_readdir_fuse_reply__failed[] = "fuse_readdir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_release_fuse_reply__failed[] = "fuse_release(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_session_receive_buf_failed[] = "fuse_session_receive_buf failed with "; static const char __pyx_k_fuse_setattr_fuse_reply__failed[] = "fuse_setattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_setxattr_non_zero_position[] = "fuse_setxattr(): non-zero position (%d) not supported"; static const char __pyx_k_fuse_symlink_fuse_reply__failed[] = "fuse_symlink(): fuse_reply_* failed with %s"; static const char __pyx_k_home_nikratio_in_progress_pytho[] = "/home/nikratio/in-progress/python-llfuse/src/operations.pxi"; static const char __pyx_k_llfuse_pxy_Copyright_2013_Nikol[] = "\nllfuse.pxy\n\nCopyright \302\251 2013 Nikolaus Rath \n\nThis file is part of Python-LLFUSE. This work may be distributed under\nthe terms of the GNU LGPL.\n"; static const char __pyx_k_mountpoint__argument_must_be_of[] = "*mountpoint_* argument must be of type str"; static const char __pyx_k_name_argument_must_be_of_type_s[] = "*name* argument must be of type str"; static const char __pyx_k_namespace_parameter_must_be_sys[] = "*namespace* parameter must be \"system\" or \"user\", not %s"; static const char __pyx_k_path_argument_must_be_of_type_s[] = "*path* argument must be of type str"; static const char __pyx_k_pthread_mutex_ulock_failed_with[] = "pthread_mutex_ulock failed with %s"; static const char __pyx_k_Calling_fuse_session_remove_chan[] = "Calling fuse_session_remove_chan"; static const char __pyx_k_Global_lock_cannot_be_acquired_m[] = "Global lock cannot be acquired more than once"; static const char __pyx_k_Lock_can_only_be_released_by_the[] = "Lock can only be released by the holding thread"; static const char __pyx_k_Lock_still_taken_after_receiving[] = "Lock still taken after receiving unlock notification"; static const char __pyx_k_NoLockManager_instances_can_t_be[] = "NoLockManager instances can't be pickled"; static const char __pyx_k_Only_one_exception_can_be_re_rai[] = "Only one exception can be re-raised in `llfuse.main`, the following exception will be lost"; static const char __pyx_k_RequestContext_instances_can_t_b[] = "RequestContext instances can't be pickled"; static const char __pyx_k_SetattrFields_instances_can_t_be[] = "SetattrFields instances can't be pickled"; static const char __pyx_k_Terminated_main_loop_because_req[] = "Terminated main loop because request handler raised exception, re-raising.."; static const char __pyx_k_Value_too_long_to_convert_to_Pyt[] = "Value too long to convert to Python"; static const char __pyx_k_fuse_access_fuse_reply__failed_w[] = "fuse_access(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_create_fuse_reply__failed_w[] = "fuse_create(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_flush_fuse_reply__failed_wi[] = "fuse_flush(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_fsync_fuse_reply__failed_wi[] = "fuse_fsync(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_fsyncdir_fuse_reply__failed[] = "fuse_fsyncdir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_getxattr_fuse_reply__failed[] = "fuse_getxattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_link_fuse_reply__failed_wit[] = "fuse_link(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_listxattr_fuse_reply__faile[] = "fuse_listxattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_lookup_fuse_reply__failed_w[] = "fuse_lookup(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_lowlevel_notify_store_retur[] = "fuse_lowlevel_notify_store returned: "; static const char __pyx_k_fuse_mkdir_fuse_reply__failed_wi[] = "fuse_mkdir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_mknod_fuse_reply__failed_wi[] = "fuse_mknod(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_read_fuse_reply__failed_wit[] = "fuse_read(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_readlink_fuse_reply__failed[] = "fuse_readlink(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_releasedir_fuse_reply__fail[] = "fuse_releasedir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_removexattr_fuse_reply__fai[] = "fuse_removexattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_rename_fuse_reply__failed_w[] = "fuse_rename(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_rmdir_fuse_reply__failed_wi[] = "fuse_rmdir(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_setattr_clock_gettime_CLOCK[] = "fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s"; static const char __pyx_k_fuse_setxattr_fuse_reply__failed[] = "fuse_setxattr(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_setxattr_fuse_reply_err_fai[] = "fuse_setxattr(): fuse_reply_err failed with %s"; static const char __pyx_k_fuse_statfs_fuse_reply__failed_w[] = "fuse_statfs(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_unlink_fuse_reply__failed_w[] = "fuse_unlink(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_write_buf_fuse_reply__faile[] = "fuse_write_buf(): fuse_reply_* failed with %s"; static const char __pyx_k_fuse_write_fuse_reply__failed_wi[] = "fuse_write(): fuse_reply_* failed with %s"; static const char __pyx_k_handler_raised_s_exception_s_ter[] = "handler raised %s exception (%s), terminating main loop."; static const char __pyx_k_pthread_mutex_lock_failed_with_s[] = "pthread_mutex_lock failed with %s"; static const char __pyx_k_home_nikratio_in_progress_pytho_2[] = "/home/nikratio/in-progress/python-llfuse/src/misc.pxi"; static const char __pyx_k_home_nikratio_in_progress_pytho_3[] = "/home/nikratio/in-progress/python-llfuse/src/fuse_api.pxi"; static const char __pyx_k_Only_one_exception_can_be_re_rai_2[] = "Only one exception can be re-raised, the following exception will be lost:"; static PyObject *__pyx_kp_u_; static PyObject *__pyx_kp_u_Calling_fuse_lowlevel_new; static PyObject *__pyx_kp_u_Calling_fuse_mount; static PyObject *__pyx_kp_u_Calling_fuse_session_add_chan; static PyObject *__pyx_kp_u_Calling_fuse_session_destroy; static PyObject *__pyx_kp_u_Calling_fuse_session_loop; static PyObject *__pyx_kp_u_Calling_fuse_session_remove_chan; static PyObject *__pyx_kp_u_Calling_fuse_unmount; static PyObject *__pyx_n_u_Darwin; static PyObject *__pyx_n_u_ENOATTR; static PyObject *__pyx_kp_u_Exception_after_kill; static PyObject *__pyx_n_s_ExitStack; static PyObject *__pyx_kp_u_FUSE_worker_thread_d_terminated; static PyObject *__pyx_kp_u_Global_lock_cannot_be_acquired_m; static PyObject *__pyx_kp_u_Groups; static PyObject *__pyx_kp_u_Initializing_llfuse; static PyObject *__pyx_kp_u_Lock_can_only_be_released_by_the; static PyObject *__pyx_kp_u_Lock_instances_can_t_be_pickled; static PyObject *__pyx_kp_u_Lock_not_initialized; static PyObject *__pyx_kp_u_Lock_still_taken_after_receiving; static PyObject *__pyx_n_s_MemoryError; static PyObject *__pyx_kp_u_Need_to_call_init_before_main; static PyObject *__pyx_kp_u_NoLockManager_instances_can_t_be; static PyObject *__pyx_kp_u_No_workers_is_not_a_good_idea; static PyObject *__pyx_n_s_OSError; static PyObject *__pyx_kp_u_Only_one_exception_can_be_re_rai; static PyObject *__pyx_kp_u_Only_one_exception_can_be_re_rai_2; static PyObject *__pyx_n_s_Operations; static PyObject *__pyx_n_s_Operations_access; static PyObject *__pyx_n_s_Operations_create; static PyObject *__pyx_n_s_Operations_destroy; static PyObject *__pyx_n_s_Operations_flush; static PyObject *__pyx_n_s_Operations_forget; static PyObject *__pyx_n_s_Operations_fsync; static PyObject *__pyx_n_s_Operations_fsyncdir; static PyObject *__pyx_n_s_Operations_getattr; static PyObject *__pyx_n_s_Operations_getxattr; static PyObject *__pyx_n_s_Operations_init; static PyObject *__pyx_n_s_Operations_link; static PyObject *__pyx_n_s_Operations_listxattr; static PyObject *__pyx_n_s_Operations_lookup; static PyObject *__pyx_n_s_Operations_mkdir; static PyObject *__pyx_n_s_Operations_mknod; static PyObject *__pyx_n_s_Operations_open; static PyObject *__pyx_n_s_Operations_opendir; static PyObject *__pyx_n_s_Operations_read; static PyObject *__pyx_n_s_Operations_readdir; static PyObject *__pyx_n_s_Operations_readlink; static PyObject *__pyx_n_s_Operations_release; static PyObject *__pyx_n_s_Operations_releasedir; static PyObject *__pyx_n_s_Operations_removexattr; static PyObject *__pyx_n_s_Operations_rename; static PyObject *__pyx_n_s_Operations_rmdir; static PyObject *__pyx_n_s_Operations_setattr; static PyObject *__pyx_n_s_Operations_setxattr; static PyObject *__pyx_n_s_Operations_stacktrace; static PyObject *__pyx_n_s_Operations_statfs; static PyObject *__pyx_n_s_Operations_symlink; static PyObject *__pyx_n_s_Operations_unlink; static PyObject *__pyx_n_s_Operations_write; static PyObject *__pyx_kp_u_Other_thread_didn_t_take_lock; static PyObject *__pyx_n_s_OverflowError; static PyObject *__pyx_n_s_PicklingError; static PyObject *__pyx_kp_b_Python_LLFUSE; static PyObject *__pyx_n_s_Queue; static PyObject *__pyx_n_s_ROOT_INODE; static PyObject *__pyx_kp_u_RequestContext_instances_can_t_b; static PyObject *__pyx_n_s_RuntimeError; static PyObject *__pyx_kp_u_SetattrFields_instances_can_t_be; static PyObject *__pyx_kp_u_Terminated_main_loop_because_req; static PyObject *__pyx_kp_s_This_class_defines_the_general; static PyObject *__pyx_n_s_Thread; static PyObject *__pyx_kp_u_ThreadID_s; static PyObject *__pyx_n_s_TypeError; static PyObject *__pyx_kp_u_Unable_to_parse_s; static PyObject *__pyx_n_s_ValueError; static PyObject *__pyx_kp_u_Value_too_long_to_convert_to_Pyt; static PyObject *__pyx_kp_u_Weird_request_kind_received_d; static PyObject *__pyx_kp_u_You_should_not_instantiate_this; static PyObject *__pyx_kp_b__35; static PyObject *__pyx_n_s_abspath; static PyObject *__pyx_n_s_access; static PyObject *__pyx_n_s_acquire; static PyObject *__pyx_n_s_attr; static PyObject *__pyx_n_s_attr_only; static PyObject *__pyx_n_u_attr_timeout; static PyObject *__pyx_n_s_basename; static PyObject *__pyx_n_u_big_writes; static PyObject *__pyx_n_s_block; static PyObject *__pyx_n_s_buf; static PyObject *__pyx_n_s_bufsize; static PyObject *__pyx_n_s_bufvec; static PyObject *__pyx_n_s_callback; static PyObject *__pyx_n_s_close; static PyObject *__pyx_n_s_cname; static PyObject *__pyx_n_s_cnamespace; static PyObject *__pyx_n_s_code; static PyObject *__pyx_n_s_contextlib; static PyObject *__pyx_n_s_contextlib2; static PyObject *__pyx_n_s_count; static PyObject *__pyx_n_s_cpath; static PyObject *__pyx_n_s_create; static PyObject *__pyx_n_s_ctx; static PyObject *__pyx_n_s_current_frames; static PyObject *__pyx_n_s_current_thread; static PyObject *__pyx_n_s_cvalue; static PyObject *__pyx_n_s_daemon; static PyObject *__pyx_n_s_data; static PyObject *__pyx_n_s_datasync; static PyObject *__pyx_n_s_debug; static PyObject *__pyx_n_s_decode; static PyObject *__pyx_n_s_default_options; static PyObject *__pyx_n_u_default_permissions; static PyObject *__pyx_n_s_destroy; static PyObject *__pyx_n_s_dirp; static PyObject *__pyx_n_s_doc; static PyObject *__pyx_n_s_encode; static PyObject *__pyx_n_s_enter; static PyObject *__pyx_n_u_entry_timeout; static PyObject *__pyx_n_s_enumerate; static PyObject *__pyx_n_s_errno; static PyObject *__pyx_kp_u_errno_d; static PyObject *__pyx_n_s_error; static PyObject *__pyx_n_s_exc_info; static PyObject *__pyx_n_s_exc_tb; static PyObject *__pyx_n_s_exc_type; static PyObject *__pyx_n_s_exc_val; static PyObject *__pyx_n_s_exception; static PyObject *__pyx_n_s_exit; static PyObject *__pyx_n_s_extract_stack; static PyObject *__pyx_n_s_f_args; static PyObject *__pyx_n_u_f_bavail; static PyObject *__pyx_n_u_f_bfree; static PyObject *__pyx_n_u_f_blocks; static PyObject *__pyx_n_u_f_bsize; static PyObject *__pyx_n_u_f_favail; static PyObject *__pyx_n_u_f_ffree; static PyObject *__pyx_n_u_f_files; static PyObject *__pyx_n_u_f_frsize; static PyObject *__pyx_n_u_f_namemax; static PyObject *__pyx_n_s_fh; static PyObject *__pyx_n_s_fields; static PyObject *__pyx_n_s_filename; static PyObject *__pyx_n_s_flags; static PyObject *__pyx_n_s_flush; static PyObject *__pyx_n_s_forget; static PyObject *__pyx_n_s_frame; static PyObject *__pyx_n_s_fse; static PyObject *__pyx_n_s_fsync; static PyObject *__pyx_n_s_fsyncdir; static PyObject *__pyx_kp_u_fuse_access_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_buf_copy_failed_with; static PyObject *__pyx_kp_u_fuse_create_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_flush_fuse_reply__failed_wi; static PyObject *__pyx_kp_u_fuse_fsync_fuse_reply__failed_wi; static PyObject *__pyx_kp_u_fuse_fsyncdir_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_getattr_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_getxattr_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_getxattr_non_zero_position; static PyObject *__pyx_kp_u_fuse_link_fuse_reply__failed_wit; static PyObject *__pyx_kp_u_fuse_listxattr_fuse_reply__faile; static PyObject *__pyx_kp_u_fuse_lookup_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_lowlevel_new_failed; static PyObject *__pyx_kp_u_fuse_lowlevel_notify_store_retur; static PyObject *__pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi; static PyObject *__pyx_kp_u_fuse_mknod_fuse_reply__failed_wi; static PyObject *__pyx_kp_u_fuse_mount_failed; static PyObject *__pyx_kp_u_fuse_opendir_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_read_fuse_reply__failed_wit; static PyObject *__pyx_kp_u_fuse_readdir_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_readlink_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_release_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_releasedir_fuse_reply__fail; static PyObject *__pyx_kp_u_fuse_removexattr_fuse_reply__fai; static PyObject *__pyx_kp_u_fuse_rename_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi; static PyObject *__pyx_kp_u_fuse_session_receive_buf_failed; static PyObject *__pyx_kp_u_fuse_setattr_clock_gettime_CLOCK; static PyObject *__pyx_kp_u_fuse_setattr_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_setxattr_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_setxattr_fuse_reply_err_fai; static PyObject *__pyx_kp_u_fuse_setxattr_non_zero_position; static PyObject *__pyx_kp_u_fuse_statfs_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_symlink_fuse_reply__failed; static PyObject *__pyx_kp_u_fuse_unlink_fuse_reply__failed_w; static PyObject *__pyx_kp_u_fuse_worker_d; static PyObject *__pyx_kp_u_fuse_write_buf_fuse_reply__faile; static PyObject *__pyx_kp_u_fuse_write_fuse_reply__failed_wi; static PyObject *__pyx_n_u_generation; static PyObject *__pyx_n_s_get; static PyObject *__pyx_n_s_getLogger; static PyObject *__pyx_n_s_get_ino_t_bits; static PyObject *__pyx_n_s_get_off_t_bits; static PyObject *__pyx_n_s_get_sup_groups; static PyObject *__pyx_n_s_getattr; static PyObject *__pyx_n_s_getfilesystemencoding; static PyObject *__pyx_n_s_getxattr; static PyObject *__pyx_n_s_gids; static PyObject *__pyx_kp_u_handler_raised_s_exception_s_ter; static PyObject *__pyx_kp_s_home_nikratio_in_progress_pytho; static PyObject *__pyx_kp_s_home_nikratio_in_progress_pytho_2; static PyObject *__pyx_kp_s_home_nikratio_in_progress_pytho_3; static PyObject *__pyx_n_s_import; static PyObject *__pyx_n_s_info; static PyObject *__pyx_n_s_init; static PyObject *__pyx_n_s_ino; static PyObject *__pyx_n_s_inode; static PyObject *__pyx_n_s_inode_list; static PyObject *__pyx_n_s_inode_p; static PyObject *__pyx_n_s_invalidate_entry; static PyObject *__pyx_n_s_invalidate_inode; static PyObject *__pyx_n_s_items; static PyObject *__pyx_n_s_join; static PyObject *__pyx_n_s_len; static PyObject *__pyx_n_s_line; static PyObject *__pyx_n_s_lineno; static PyObject *__pyx_n_s_link; static PyObject *__pyx_n_s_listdir; static PyObject *__pyx_n_s_listxattr; static PyObject *__pyx_n_s_llfuse; static PyObject *__pyx_n_u_llfuse; static PyObject *__pyx_n_s_lock; static PyObject *__pyx_n_s_lock_released; static PyObject *__pyx_n_s_log; static PyObject *__pyx_n_s_logging; static PyObject *__pyx_n_s_lookup; static PyObject *__pyx_n_s_main; static PyObject *__pyx_n_s_main_2; static PyObject *__pyx_n_s_main_locals_lambda; static PyObject *__pyx_n_s_maxsize; static PyObject *__pyx_n_s_metaclass; static PyObject *__pyx_n_s_mkdir; static PyObject *__pyx_n_s_mknod; static PyObject *__pyx_n_s_mode; static PyObject *__pyx_n_s_module; static PyObject *__pyx_n_s_mountpoint; static PyObject *__pyx_kp_u_mountpoint__argument_must_be_of; static PyObject *__pyx_n_s_name; static PyObject *__pyx_kp_u_name_argument_must_be_of_type_s; static PyObject *__pyx_n_s_name_b; static PyObject *__pyx_n_s_name_new; static PyObject *__pyx_n_s_name_old; static PyObject *__pyx_n_s_names; static PyObject *__pyx_n_s_namespace; static PyObject *__pyx_kp_u_namespace_parameter_must_be_sys; static PyObject *__pyx_n_s_new_name; static PyObject *__pyx_n_s_new_parent_inode; static PyObject *__pyx_n_u_no_splice_read; static PyObject *__pyx_n_u_nonempty; static PyObject *__pyx_n_s_notify_loop; static PyObject *__pyx_n_s_notify_store; static PyObject *__pyx_kp_b_o; static PyObject *__pyx_n_s_object; static PyObject *__pyx_n_s_off; static PyObject *__pyx_n_s_offset; static PyObject *__pyx_n_s_on_exit; static PyObject *__pyx_n_s_open; static PyObject *__pyx_n_s_opendir; static PyObject *__pyx_n_s_ops; static PyObject *__pyx_n_s_options; static PyObject *__pyx_n_s_os; static PyObject *__pyx_n_s_os_path; static PyObject *__pyx_n_s_parent_inode; static PyObject *__pyx_n_s_parent_inode_new; static PyObject *__pyx_n_s_parent_inode_old; static PyObject *__pyx_n_s_path; static PyObject *__pyx_kp_u_path_argument_must_be_of_type_s; static PyObject *__pyx_n_s_path_b; static PyObject *__pyx_n_s_pickle; static PyObject *__pyx_n_s_pid; static PyObject *__pyx_n_s_prepare; static PyObject *__pyx_kp_u_proc_d_status; static PyObject *__pyx_kp_u_pthread_create_failed_with; static PyObject *__pyx_kp_u_pthread_join_failed_with_s; static PyObject *__pyx_kp_u_pthread_kill_failed_with_s; static PyObject *__pyx_kp_u_pthread_mutex_lock_failed_with_s; static PyObject *__pyx_kp_u_pthread_mutex_ulock_failed_with; static PyObject *__pyx_n_s_put; static PyObject *__pyx_n_s_pybuf; static PyObject *__pyx_n_s_qualname; static PyObject *__pyx_n_s_queue; static PyObject *__pyx_n_u_r; static PyObject *__pyx_n_s_range; static PyObject *__pyx_n_s_rdev; static PyObject *__pyx_n_s_read; static PyObject *__pyx_n_s_readdir; static PyObject *__pyx_n_s_readlink; static PyObject *__pyx_n_s_release; static PyObject *__pyx_n_s_releasedir; static PyObject *__pyx_n_s_removexattr; static PyObject *__pyx_n_s_rename; static PyObject *__pyx_n_s_req; static PyObject *__pyx_n_s_res; static PyObject *__pyx_n_s_ret; static PyObject *__pyx_n_s_rmdir; static PyObject *__pyx_kp_u_s; static PyObject *__pyx_kp_u_s_d_in_s; static PyObject *__pyx_n_s_self; static PyObject *__pyx_kp_u_sem_init_failed_with; static PyObject *__pyx_n_s_setattr; static PyObject *__pyx_n_s_setxattr; static PyObject *__pyx_kp_u_sigaction_failed_with; static PyObject *__pyx_n_s_size; static PyObject *__pyx_n_s_size_guess; static PyObject *__pyx_n_u_splice_move; static PyObject *__pyx_n_u_splice_write; static PyObject *__pyx_n_s_split; static PyObject *__pyx_n_u_st_atime_ns; static PyObject *__pyx_n_u_st_birthtime_ns; static PyObject *__pyx_n_u_st_blksize; static PyObject *__pyx_n_u_st_blocks; static PyObject *__pyx_n_u_st_ctime_ns; static PyObject *__pyx_n_u_st_gid; static PyObject *__pyx_n_u_st_ino; static PyObject *__pyx_n_u_st_mode; static PyObject *__pyx_n_u_st_mtime_ns; static PyObject *__pyx_n_u_st_nlink; static PyObject *__pyx_n_u_st_rdev; static PyObject *__pyx_n_u_st_size; static PyObject *__pyx_n_u_st_uid; static PyObject *__pyx_n_s_stacktrace; static PyObject *__pyx_n_s_start; static PyObject *__pyx_n_s_startswith; static PyObject *__pyx_n_s_statfs; static PyObject *__pyx_n_s_str_t; static PyObject *__pyx_n_s_strerror; static PyObject *__pyx_n_s_strip; static PyObject *__pyx_n_u_surrogateescape; static PyObject *__pyx_n_s_symlink; static PyObject *__pyx_n_s_sys; static PyObject *__pyx_n_u_system; static PyObject *__pyx_n_s_t; static PyObject *__pyx_n_s_target; static PyObject *__pyx_n_s_test; static PyObject *__pyx_n_s_threadId; static PyObject *__pyx_n_s_threading; static PyObject *__pyx_n_s_timeout; static PyObject *__pyx_n_s_tmp; static PyObject *__pyx_n_s_traceback; static PyObject *__pyx_n_s_uname; static PyObject *__pyx_kp_u_unknown_flag_s_o; static PyObject *__pyx_n_s_unlink; static PyObject *__pyx_n_s_unmount; static PyObject *__pyx_kp_u_us_ascii; static PyObject *__pyx_n_u_user; static PyObject *__pyx_n_s_value; static PyObject *__pyx_n_s_version; static PyObject *__pyx_n_s_with_traceback; static PyObject *__pyx_n_s_workers; static PyObject *__pyx_n_s_write; static PyObject *__pyx_n_s_x; static PyObject *__pyx_pf_6llfuse_10Operations_init(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_2destroy(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_4lookup(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_6forget(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode_list); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_8getattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_10setattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_attr, CYTHON_UNUSED PyObject *__pyx_v_fields, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_12readlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_14mknod(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_rdev, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_16mkdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_18unlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_20rmdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_22symlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_target, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_24rename(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode_old, CYTHON_UNUSED PyObject *__pyx_v_name_old, CYTHON_UNUSED PyObject *__pyx_v_parent_inode_new, CYTHON_UNUSED PyObject *__pyx_v_name_new, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_26link(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_new_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_new_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_28open(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_flags, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_30read(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off, CYTHON_UNUSED PyObject *__pyx_v_size); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_32write(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off, CYTHON_UNUSED PyObject *__pyx_v_buf); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_34flush(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_36release(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_38fsync(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_datasync); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_40opendir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_42readdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_44releasedir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_46fsyncdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_datasync); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_48statfs(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_50stacktrace(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_52setxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_value, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_54getxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_56listxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_58removexattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_60access(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static PyObject *__pyx_pf_6llfuse_10Operations_62create(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_flags, CYTHON_UNUSED PyObject *__pyx_v_ctx); /* proto */ static int __pyx_pf_6llfuse_4Lock___init__(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_2acquire(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self, PyObject *__pyx_v_timeout); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_4release(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_6yield_(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self, PyObject *__pyx_v_count); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_8__enter__(struct __pyx_obj_6llfuse_Lock *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_10__exit__(struct __pyx_obj_6llfuse_Lock *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_exc_type, CYTHON_UNUSED PyObject *__pyx_v_exc_val, CYTHON_UNUSED PyObject *__pyx_v_exc_tb); /* proto */ static PyObject *__pyx_pf_6llfuse_4Lock_12__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_13NoLockManager___init__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13NoLockManager_2__enter__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13NoLockManager_4__exit__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_a); /* proto */ static PyObject *__pyx_pf_6llfuse_13NoLockManager_6__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse__notify_loop(CYTHON_UNUSED PyObject *__pyx_self); /* proto */ static PyObject *__pyx_pf_6llfuse_14RequestContext___getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_14RequestContext_3uid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_14RequestContext_3pid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_14RequestContext_3gid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_14RequestContext_5umask___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_13SetattrFields___cinit__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_2__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_12update_atime___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_12update_mtime___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_11update_mode___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_10update_uid___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_10update_gid___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_13SetattrFields_11update_size___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes___cinit__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_ino___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_6st_ino_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_10generation___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_10generation_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_12attr_timeout___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_12attr_timeout_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_13entry_timeout___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_13entry_timeout_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_mode___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_7st_mode_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_8st_nlink___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_8st_nlink_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_uid___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_6st_uid_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_gid___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_6st_gid_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_rdev___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_7st_rdev_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_size___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_7st_size_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_9st_blocks___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_9st_blocks_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_10st_blksize___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_10st_blksize_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_2__getstate__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_15EntryAttributes_4__setstate__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_state); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData___cinit__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_bsize___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_7f_bsize_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_frsize___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_8f_frsize_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_blocks___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_8f_blocks_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_bfree___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_7f_bfree_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_bavail___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_8f_bavail_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_files___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_7f_files_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_ffree___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_7f_ffree_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_favail___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_8f_favail_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_9f_namemax___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_11StatvfsData_9f_namemax_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_2__getstate__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_11StatvfsData_4__setstate__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_state); /* proto */ static PyObject *__pyx_pf_6llfuse_9FUSEError_5errno___get__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self); /* proto */ static int __pyx_pf_6llfuse_9FUSEError___cinit__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self, PyObject *__pyx_v_errno); /* proto */ static PyObject *__pyx_pf_6llfuse_9FUSEError_2__str__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_9FUSEError_6errno____get__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self); /* proto */ static PyObject *__pyx_pf_6llfuse_2listdir(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path); /* proto */ static PyObject *__pyx_pf_6llfuse_4setxattr(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path, PyObject *__pyx_v_name, PyObject *__pyx_v_value, PyObject *__pyx_v_namespace); /* proto */ static PyObject *__pyx_pf_6llfuse_6getxattr(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path, PyObject *__pyx_v_name, size_t __pyx_v_size_guess, PyObject *__pyx_v_namespace); /* proto */ static PyObject *__pyx_pf_6llfuse_8init(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_ops, PyObject *__pyx_v_mountpoint, PyObject *__pyx_v_options); /* proto */ static PyObject *__pyx_lambda_funcdef_lambda(CYTHON_UNUSED PyObject *__pyx_self); /* proto */ static PyObject *__pyx_lambda_funcdef_lambda1(CYTHON_UNUSED PyObject *__pyx_self); /* proto */ static PyObject *__pyx_pf_6llfuse_10main(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_workers); /* proto */ static PyObject *__pyx_pf_6llfuse_12close(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_unmount); /* proto */ static PyObject *__pyx_pf_6llfuse_14invalidate_inode(CYTHON_UNUSED PyObject *__pyx_self, fuse_ino_t __pyx_v_inode, PyObject *__pyx_v_attr_only); /* proto */ static PyObject *__pyx_pf_6llfuse_16invalidate_entry(CYTHON_UNUSED PyObject *__pyx_self, fuse_ino_t __pyx_v_inode_p, PyObject *__pyx_v_name); /* proto */ static PyObject *__pyx_pf_6llfuse_18get_ino_t_bits(CYTHON_UNUSED PyObject *__pyx_self); /* proto */ static PyObject *__pyx_pf_6llfuse_20get_off_t_bits(CYTHON_UNUSED PyObject *__pyx_self); /* proto */ static PyObject *__pyx_pf_6llfuse_22notify_store(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_inode, PyObject *__pyx_v_offset, PyObject *__pyx_v_data); /* proto */ static PyObject *__pyx_pf_6llfuse_24get_sup_groups(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_pid); /* proto */ static PyObject *__pyx_tp_new_6llfuse_Lock(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_NoLockManager(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_RequestContext(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_SetattrFields(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_EntryAttributes(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_StatvfsData(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_FUSEError(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_NotifyRequest(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_tp_new_6llfuse_VoidPtrCapsule(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/ static PyObject *__pyx_int_0; static PyObject *__pyx_int_1; static PyObject *__pyx_int_5; static PyObject *__pyx_int_30; static PyObject *__pyx_int_1000; static PyObject *__pyx_int_1000000000; static PyObject *__pyx_k__65; static PyObject *__pyx_tuple__2; static PyObject *__pyx_tuple__3; static PyObject *__pyx_tuple__4; static PyObject *__pyx_tuple__5; static PyObject *__pyx_tuple__6; static PyObject *__pyx_tuple__7; static PyObject *__pyx_tuple__8; static PyObject *__pyx_tuple__9; static PyObject *__pyx_slice__84; static PyObject *__pyx_tuple__10; static PyObject *__pyx_tuple__11; static PyObject *__pyx_tuple__12; static PyObject *__pyx_tuple__13; static PyObject *__pyx_tuple__14; static PyObject *__pyx_tuple__15; static PyObject *__pyx_tuple__16; static PyObject *__pyx_tuple__17; static PyObject *__pyx_tuple__18; static PyObject *__pyx_tuple__19; static PyObject *__pyx_tuple__20; static PyObject *__pyx_tuple__21; static PyObject *__pyx_tuple__22; static PyObject *__pyx_tuple__23; static PyObject *__pyx_tuple__24; static PyObject *__pyx_tuple__25; static PyObject *__pyx_tuple__26; static PyObject *__pyx_tuple__27; static PyObject *__pyx_tuple__28; static PyObject *__pyx_tuple__29; static PyObject *__pyx_tuple__30; static PyObject *__pyx_tuple__31; static PyObject *__pyx_tuple__32; static PyObject *__pyx_tuple__33; static PyObject *__pyx_tuple__34; static PyObject *__pyx_tuple__36; static PyObject *__pyx_tuple__37; static PyObject *__pyx_tuple__38; static PyObject *__pyx_tuple__39; static PyObject *__pyx_tuple__40; static PyObject *__pyx_tuple__41; static PyObject *__pyx_tuple__42; static PyObject *__pyx_tuple__43; static PyObject *__pyx_tuple__44; static PyObject *__pyx_tuple__45; static PyObject *__pyx_tuple__46; static PyObject *__pyx_tuple__47; static PyObject *__pyx_tuple__48; static PyObject *__pyx_tuple__49; static PyObject *__pyx_tuple__50; static PyObject *__pyx_tuple__51; static PyObject *__pyx_tuple__52; static PyObject *__pyx_tuple__53; static PyObject *__pyx_tuple__54; static PyObject *__pyx_tuple__55; static PyObject *__pyx_tuple__56; static PyObject *__pyx_tuple__57; static PyObject *__pyx_tuple__58; static PyObject *__pyx_tuple__59; static PyObject *__pyx_tuple__60; static PyObject *__pyx_tuple__61; static PyObject *__pyx_tuple__62; static PyObject *__pyx_tuple__63; static PyObject *__pyx_tuple__64; static PyObject *__pyx_tuple__66; static PyObject *__pyx_tuple__67; static PyObject *__pyx_tuple__68; static PyObject *__pyx_tuple__69; static PyObject *__pyx_tuple__70; static PyObject *__pyx_tuple__71; static PyObject *__pyx_tuple__72; static PyObject *__pyx_tuple__73; static PyObject *__pyx_tuple__74; static PyObject *__pyx_tuple__75; static PyObject *__pyx_tuple__76; static PyObject *__pyx_tuple__77; static PyObject *__pyx_tuple__78; static PyObject *__pyx_tuple__79; static PyObject *__pyx_tuple__80; static PyObject *__pyx_tuple__81; static PyObject *__pyx_tuple__82; static PyObject *__pyx_tuple__83; static PyObject *__pyx_tuple__85; static PyObject *__pyx_tuple__86; static PyObject *__pyx_tuple__88; static PyObject *__pyx_tuple__90; static PyObject *__pyx_tuple__92; static PyObject *__pyx_tuple__94; static PyObject *__pyx_tuple__96; static PyObject *__pyx_tuple__98; static PyObject *__pyx_tuple__100; static PyObject *__pyx_tuple__102; static PyObject *__pyx_tuple__104; static PyObject *__pyx_tuple__106; static PyObject *__pyx_tuple__108; static PyObject *__pyx_tuple__110; static PyObject *__pyx_tuple__112; static PyObject *__pyx_tuple__114; static PyObject *__pyx_tuple__116; static PyObject *__pyx_tuple__118; static PyObject *__pyx_tuple__120; static PyObject *__pyx_tuple__122; static PyObject *__pyx_tuple__124; static PyObject *__pyx_tuple__126; static PyObject *__pyx_tuple__128; static PyObject *__pyx_tuple__130; static PyObject *__pyx_tuple__132; static PyObject *__pyx_tuple__134; static PyObject *__pyx_tuple__136; static PyObject *__pyx_tuple__138; static PyObject *__pyx_tuple__140; static PyObject *__pyx_tuple__142; static PyObject *__pyx_tuple__144; static PyObject *__pyx_tuple__146; static PyObject *__pyx_tuple__148; static PyObject *__pyx_tuple__150; static PyObject *__pyx_tuple__152; static PyObject *__pyx_tuple__154; static PyObject *__pyx_tuple__156; static PyObject *__pyx_tuple__158; static PyObject *__pyx_tuple__159; static PyObject *__pyx_tuple__160; static PyObject *__pyx_tuple__162; static PyObject *__pyx_tuple__164; static PyObject *__pyx_tuple__166; static PyObject *__pyx_tuple__168; static PyObject *__pyx_tuple__172; static PyObject *__pyx_tuple__174; static PyObject *__pyx_codeobj__87; static PyObject *__pyx_codeobj__89; static PyObject *__pyx_codeobj__91; static PyObject *__pyx_codeobj__93; static PyObject *__pyx_codeobj__95; static PyObject *__pyx_codeobj__97; static PyObject *__pyx_codeobj__99; static PyObject *__pyx_codeobj__101; static PyObject *__pyx_codeobj__103; static PyObject *__pyx_codeobj__105; static PyObject *__pyx_codeobj__107; static PyObject *__pyx_codeobj__109; static PyObject *__pyx_codeobj__111; static PyObject *__pyx_codeobj__113; static PyObject *__pyx_codeobj__115; static PyObject *__pyx_codeobj__117; static PyObject *__pyx_codeobj__119; static PyObject *__pyx_codeobj__121; static PyObject *__pyx_codeobj__123; static PyObject *__pyx_codeobj__125; static PyObject *__pyx_codeobj__127; static PyObject *__pyx_codeobj__129; static PyObject *__pyx_codeobj__131; static PyObject *__pyx_codeobj__133; static PyObject *__pyx_codeobj__135; static PyObject *__pyx_codeobj__137; static PyObject *__pyx_codeobj__139; static PyObject *__pyx_codeobj__141; static PyObject *__pyx_codeobj__143; static PyObject *__pyx_codeobj__145; static PyObject *__pyx_codeobj__147; static PyObject *__pyx_codeobj__149; static PyObject *__pyx_codeobj__151; static PyObject *__pyx_codeobj__153; static PyObject *__pyx_codeobj__155; static PyObject *__pyx_codeobj__157; static PyObject *__pyx_codeobj__161; static PyObject *__pyx_codeobj__163; static PyObject *__pyx_codeobj__165; static PyObject *__pyx_codeobj__167; static PyObject *__pyx_codeobj__169; static PyObject *__pyx_codeobj__170; static PyObject *__pyx_codeobj__171; static PyObject *__pyx_codeobj__173; static PyObject *__pyx_codeobj__175; /* "src/operations.pxi":28 * ''' * * def init(self): # <<<<<<<<<<<<<< * '''Initialize operations * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_1init(PyObject *__pyx_self, PyObject *__pyx_v_self); /*proto*/ static char __pyx_doc_6llfuse_10Operations_init[] = "Operations.init(self)\nInitialize operations\n\n This method will be called just before the file system starts handling\n requests. It must not raise any exceptions (not even `FUSEError`), since\n it is not handling a particular client request.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_1init = {"init", (PyCFunction)__pyx_pw_6llfuse_10Operations_1init, METH_O, __pyx_doc_6llfuse_10Operations_init}; static PyObject *__pyx_pw_6llfuse_10Operations_1init(PyObject *__pyx_self, PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("init (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_10Operations_init(__pyx_self, ((PyObject *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_init(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("init", 0); /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":38 * pass * * def destroy(self): # <<<<<<<<<<<<<< * '''Clean up operations. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_3destroy(PyObject *__pyx_self, PyObject *__pyx_v_self); /*proto*/ static char __pyx_doc_6llfuse_10Operations_2destroy[] = "Operations.destroy(self)\nClean up operations.\n\n This method will be called when `llfuse.close` has been called and the\n file system is about to be unmounted.\n\n This method must not raise any exceptions (not even `FUSEError`), since\n it is not handling a particular client request.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_3destroy = {"destroy", (PyCFunction)__pyx_pw_6llfuse_10Operations_3destroy, METH_O, __pyx_doc_6llfuse_10Operations_2destroy}; static PyObject *__pyx_pw_6llfuse_10Operations_3destroy(PyObject *__pyx_self, PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("destroy (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_10Operations_2destroy(__pyx_self, ((PyObject *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_2destroy(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("destroy", 0); /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":50 * pass * * def lookup(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Look up a directory entry by name and get its attributes. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_5lookup(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_4lookup[] = "Operations.lookup(self, parent_inode, name, ctx)\nLook up a directory entry by name and get its attributes.\n\n This method should return an `EntryAttributes` instance for the\n directory entry *name* in the directory with inode *parent_inode*.\n\n If there is no such entry, the method should either return an\n `EntryAttributes` instance with zero ``st_ino`` value (in which case\n the negative lookup will be cached as specified by ``entry_timeout``),\n or it should raise `FUSEError` with an errno of `errno.ENOENT` (in this\n case the negative result will not be cached).\n\n *ctx* will be a `RequestContext` instance.\n\n The file system must be able to handle lookups for :file:`.` and\n :file:`..`, no matter if these entries are returned by `readdir` or not.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_5lookup = {"lookup", (PyCFunction)__pyx_pw_6llfuse_10Operations_5lookup, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_4lookup}; static PyObject *__pyx_pw_6llfuse_10Operations_5lookup(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("lookup (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("lookup", 1, 4, 4, 1); __PYX_ERR(0, 50, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("lookup", 1, 4, 4, 2); __PYX_ERR(0, 50, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("lookup", 1, 4, 4, 3); __PYX_ERR(0, 50, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "lookup") < 0)) __PYX_ERR(0, 50, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("lookup", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 50, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.lookup", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_4lookup(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_4lookup(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("lookup", 0); /* "src/operations.pxi":71 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def forget(self, inode_list): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 71, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 71, __pyx_L1_error) /* "src/operations.pxi":50 * pass * * def lookup(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Look up a directory entry by name and get its attributes. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.lookup", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":73 * raise FUSEError(errno.ENOSYS) * * def forget(self, inode_list): # <<<<<<<<<<<<<< * '''Decrease lookup counts for inodes in *inode_list* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_7forget(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_6forget[] = "Operations.forget(self, inode_list)\nDecrease lookup counts for inodes in *inode_list*\n\n *inode_list* is a list of ``(inode, nlookup)`` tuples. This method\n should reduce the lookup count for each *inode* by *nlookup*.\n\n If the lookup count reaches zero, the inode is currently not known to\n the kernel. In this case, the file system will typically check if there\n are still directory entries referring to this inode and, if not, remove\n the inode.\n\n If the file system is unmounted, it may not have received `forget` calls\n to bring all lookup counts to zero. The `destroy` method should be used\n to clean up inodes that at that point still have non-zero lookup count\n (e.g. by calling `forget` with the current lookup count for every such\n inode).\n\n This method must not raise any exceptions (not even `FUSEError`), since\n it is not handling a particular client request.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_7forget = {"forget", (PyCFunction)__pyx_pw_6llfuse_10Operations_7forget, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_6forget}; static PyObject *__pyx_pw_6llfuse_10Operations_7forget(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode_list = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("forget (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode_list,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode_list)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("forget", 1, 2, 2, 1); __PYX_ERR(0, 73, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "forget") < 0)) __PYX_ERR(0, 73, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_self = values[0]; __pyx_v_inode_list = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("forget", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 73, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.forget", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_6forget(__pyx_self, __pyx_v_self, __pyx_v_inode_list); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_6forget(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode_list) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("forget", 0); /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":96 * pass * * def getattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get attributes for *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_9getattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_8getattr[] = "Operations.getattr(self, inode, ctx)\nGet attributes for *inode*\n\n *ctx* will be a `RequestContext` instance.\n\n This method should return an `EntryAttributes` instance with the\n attributes of *inode*. The `~EntryAttributes.entry_timeout` attribute is\n ignored in this context.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_9getattr = {"getattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_9getattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_8getattr}; static PyObject *__pyx_pw_6llfuse_10Operations_9getattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("getattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_ctx,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getattr", 1, 3, 3, 1); __PYX_ERR(0, 96, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getattr", 1, 3, 3, 2); __PYX_ERR(0, 96, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getattr") < 0)) __PYX_ERR(0, 96, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_ctx = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("getattr", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 96, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.getattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_8getattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_8getattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("getattr", 0); /* "src/operations.pxi":106 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 106, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 106, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 106, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 106, __pyx_L1_error) /* "src/operations.pxi":96 * pass * * def getattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get attributes for *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.getattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":109 * * * def setattr(self, inode, attr, fields, fh, ctx): # <<<<<<<<<<<<<< * '''Change attributes of *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_11setattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_10setattr[] = "Operations.setattr(self, inode, attr, fields, fh, ctx)\nChange attributes of *inode*\n\n *fields* will be an `SetattrFields` instance that specifies which\n attributes are to be updated. *attr* will be an `EntryAttributes`\n instance for *inode* that contains the new values for changed\n attributes, and undefined values for all other attributes.\n\n Most file systems will additionally set the\n `~EntryAttributes.st_ctime_ns` attribute to the current time (to\n indicate that the inode metadata was changed).\n\n If the syscall that is being processed received a file descriptor\n argument (like e.g. :manpage:`ftruncate(2)` or :manpage:`fchmod(2)`),\n *fh* will be the file handle returned by the corresponding call to the\n `open` handler. If the syscall was path based (like\n e.g. :manpage:`truncate(2)` or :manpage:`chmod(2)`), *fh* will be\n `None`.\n\n *ctx* will be a `RequestContext` instance.\n\n The method should return an `EntryAttributes` instance (containing both\n the changed and unchanged values).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_11setattr = {"setattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_11setattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_10setattr}; static PyObject *__pyx_pw_6llfuse_10Operations_11setattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_attr = 0; CYTHON_UNUSED PyObject *__pyx_v_fields = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("setattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_attr,&__pyx_n_s_fields,&__pyx_n_s_fh,&__pyx_n_s_ctx,0}; PyObject* values[6] = {0,0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5); case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, 1); __PYX_ERR(0, 109, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_attr)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, 2); __PYX_ERR(0, 109, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fields)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, 3); __PYX_ERR(0, 109, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, 4); __PYX_ERR(0, 109, __pyx_L3_error) } case 5: if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, 5); __PYX_ERR(0, 109, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "setattr") < 0)) __PYX_ERR(0, 109, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 6) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); values[5] = PyTuple_GET_ITEM(__pyx_args, 5); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_attr = values[2]; __pyx_v_fields = values[3]; __pyx_v_fh = values[4]; __pyx_v_ctx = values[5]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("setattr", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 109, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.setattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_10setattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_attr, __pyx_v_fields, __pyx_v_fh, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_10setattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_attr, CYTHON_UNUSED PyObject *__pyx_v_fields, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("setattr", 0); /* "src/operations.pxi":134 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def readlink(self, inode, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 134, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 134, __pyx_L1_error) /* "src/operations.pxi":109 * * * def setattr(self, inode, attr, fields, fh, ctx): # <<<<<<<<<<<<<< * '''Change attributes of *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.setattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":136 * raise FUSEError(errno.ENOSYS) * * def readlink(self, inode, ctx): # <<<<<<<<<<<<<< * '''Return target of symbolic link *inode*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_13readlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_12readlink[] = "Operations.readlink(self, inode, ctx)\nReturn target of symbolic link *inode*.\n\n *ctx* will be a `RequestContext` instance.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_13readlink = {"readlink", (PyCFunction)__pyx_pw_6llfuse_10Operations_13readlink, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_12readlink}; static PyObject *__pyx_pw_6llfuse_10Operations_13readlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("readlink (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_ctx,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("readlink", 1, 3, 3, 1); __PYX_ERR(0, 136, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("readlink", 1, 3, 3, 2); __PYX_ERR(0, 136, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "readlink") < 0)) __PYX_ERR(0, 136, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_ctx = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("readlink", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 136, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.readlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_12readlink(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_12readlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("readlink", 0); /* "src/operations.pxi":142 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 142, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 142, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 142, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 142, __pyx_L1_error) /* "src/operations.pxi":136 * raise FUSEError(errno.ENOSYS) * * def readlink(self, inode, ctx): # <<<<<<<<<<<<<< * '''Return target of symbolic link *inode*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.readlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":145 * * * def mknod(self, parent_inode, name, mode, rdev, ctx): # <<<<<<<<<<<<<< * '''Create (possibly special) file * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_15mknod(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_14mknod[] = "Operations.mknod(self, parent_inode, name, mode, rdev, ctx)\nCreate (possibly special) file\n\n This method must create a (special or regular) file *name* in the\n directory with inode *parent_inode*. Whether the file is special or\n regular is determined by its *mode*. If the file is neither a block nor\n character device, *rdev* can be ignored. *ctx* will be a\n `RequestContext` instance.\n\n The method must return an `EntryAttributes` instance with the attributes\n of the newly created directory entry.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_15mknod = {"mknod", (PyCFunction)__pyx_pw_6llfuse_10Operations_15mknod, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_14mknod}; static PyObject *__pyx_pw_6llfuse_10Operations_15mknod(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_mode = 0; CYTHON_UNUSED PyObject *__pyx_v_rdev = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("mknod (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_mode,&__pyx_n_s_rdev,&__pyx_n_s_ctx,0}; PyObject* values[6] = {0,0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5); case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, 1); __PYX_ERR(0, 145, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, 2); __PYX_ERR(0, 145, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_mode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, 3); __PYX_ERR(0, 145, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_rdev)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, 4); __PYX_ERR(0, 145, __pyx_L3_error) } case 5: if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, 5); __PYX_ERR(0, 145, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "mknod") < 0)) __PYX_ERR(0, 145, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 6) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); values[5] = PyTuple_GET_ITEM(__pyx_args, 5); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_mode = values[3]; __pyx_v_rdev = values[4]; __pyx_v_ctx = values[5]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("mknod", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 145, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.mknod", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_14mknod(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_mode, __pyx_v_rdev, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_14mknod(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_rdev, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("mknod", 0); /* "src/operations.pxi":161 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def mkdir(self, parent_inode, name, mode, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 161, __pyx_L1_error) /* "src/operations.pxi":145 * * * def mknod(self, parent_inode, name, mode, rdev, ctx): # <<<<<<<<<<<<<< * '''Create (possibly special) file * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.mknod", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":163 * raise FUSEError(errno.ENOSYS) * * def mkdir(self, parent_inode, name, mode, ctx): # <<<<<<<<<<<<<< * '''Create a directory * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_17mkdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_16mkdir[] = "Operations.mkdir(self, parent_inode, name, mode, ctx)\nCreate a directory\n\n This method must create a new directory *name* with mode *mode* in the\n directory with inode *parent_inode*. *ctx* will be a `RequestContext`\n instance.\n\n This method must return an `EntryAttributes` instance with the\n attributes of the newly created directory entry.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_17mkdir = {"mkdir", (PyCFunction)__pyx_pw_6llfuse_10Operations_17mkdir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_16mkdir}; static PyObject *__pyx_pw_6llfuse_10Operations_17mkdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_mode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("mkdir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_mode,&__pyx_n_s_ctx,0}; PyObject* values[5] = {0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mkdir", 1, 5, 5, 1); __PYX_ERR(0, 163, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mkdir", 1, 5, 5, 2); __PYX_ERR(0, 163, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_mode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mkdir", 1, 5, 5, 3); __PYX_ERR(0, 163, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("mkdir", 1, 5, 5, 4); __PYX_ERR(0, 163, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "mkdir") < 0)) __PYX_ERR(0, 163, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 5) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_mode = values[3]; __pyx_v_ctx = values[4]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("mkdir", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 163, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_16mkdir(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_mode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_16mkdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("mkdir", 0); /* "src/operations.pxi":177 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def unlink(self, parent_inode, name, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 177, __pyx_L1_error) /* "src/operations.pxi":163 * raise FUSEError(errno.ENOSYS) * * def mkdir(self, parent_inode, name, mode, ctx): # <<<<<<<<<<<<<< * '''Create a directory * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":179 * raise FUSEError(errno.ENOSYS) * * def unlink(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove a (possibly special) file * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_19unlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_18unlink[] = "Operations.unlink(self, parent_inode, name, ctx)\nRemove a (possibly special) file\n\n This method must remove the (special or regular) file *name* from the\n direcory with inode *parent_inode*. *ctx* will be a `RequestContext`\n instance.\n\n If the inode associated with *file* (i.e., not the *parent_inode*) has a\n non-zero lookup count, or if there are still other directory entries\n referring to this inode (due to hardlinks), the file system must remove\n only the directory entry (so that future calls to `readdir` for\n *parent_inode* will no longer include *name*, but e.g. calls to\n `getattr` for *file*'s inode still succeed). (Potential) removal of the\n associated inode with the file contents and metadata must be deferred to\n the `forget` method to be carried out when the lookup count reaches zero\n (and of course only if at that point there are no more directory entries\n associated with the inode either).\n\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_19unlink = {"unlink", (PyCFunction)__pyx_pw_6llfuse_10Operations_19unlink, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_18unlink}; static PyObject *__pyx_pw_6llfuse_10Operations_19unlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("unlink (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("unlink", 1, 4, 4, 1); __PYX_ERR(0, 179, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("unlink", 1, 4, 4, 2); __PYX_ERR(0, 179, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("unlink", 1, 4, 4, 3); __PYX_ERR(0, 179, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "unlink") < 0)) __PYX_ERR(0, 179, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("unlink", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 179, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.unlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_18unlink(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_18unlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("unlink", 0); /* "src/operations.pxi":199 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def rmdir(self, parent_inode, name, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 199, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 199, __pyx_L1_error) /* "src/operations.pxi":179 * raise FUSEError(errno.ENOSYS) * * def unlink(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove a (possibly special) file * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.unlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":201 * raise FUSEError(errno.ENOSYS) * * def rmdir(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove directory *name* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_21rmdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_20rmdir[] = "Operations.rmdir(self, parent_inode, name, ctx)\nRemove directory *name*\n\n This method must remove the directory *name* from the direcory with\n inode *parent_inode*. *ctx* will be a `RequestContext` instance. If\n there are still entries in the directory, the method should raise\n ``FUSEError(errno.ENOTEMPTY)``.\n\n If the inode associated with *name* (i.e., not the *parent_inode*) has a\n non-zero lookup count, the file system must remove only the directory\n entry (so that future calls to `readdir` for *parent_inode* will no\n longer include *name*, but e.g. calls to `getattr` for *file*'s inode\n still succeed). Removal of the associated inode holding the directory\n contents and metadata must be deferred to the `forget` method to be\n carried out when the lookup count reaches zero.\n\n (Since hard links to directories are not allowed by POSIX, this method\n is not required to check if there are still other directory entries\n refering to the same inode. This conveniently avoids the ambigiouties\n associated with the ``.`` and ``..`` entries).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_21rmdir = {"rmdir", (PyCFunction)__pyx_pw_6llfuse_10Operations_21rmdir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_20rmdir}; static PyObject *__pyx_pw_6llfuse_10Operations_21rmdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("rmdir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rmdir", 1, 4, 4, 1); __PYX_ERR(0, 201, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rmdir", 1, 4, 4, 2); __PYX_ERR(0, 201, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rmdir", 1, 4, 4, 3); __PYX_ERR(0, 201, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "rmdir") < 0)) __PYX_ERR(0, 201, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("rmdir", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 201, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_20rmdir(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_20rmdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("rmdir", 0); /* "src/operations.pxi":223 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def symlink(self, parent_inode, name, target, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 223, __pyx_L1_error) /* "src/operations.pxi":201 * raise FUSEError(errno.ENOSYS) * * def rmdir(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove directory *name* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":225 * raise FUSEError(errno.ENOSYS) * * def symlink(self, parent_inode, name, target, ctx): # <<<<<<<<<<<<<< * '''Create a symbolic link * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_23symlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_22symlink[] = "Operations.symlink(self, parent_inode, name, target, ctx)\nCreate a symbolic link\n\n This method must create a symbolink link named *name* in the directory\n with inode *parent_inode*, pointing to *target*. *ctx* will be a\n `RequestContext` instance.\n\n The method must return an `EntryAttributes` instance with the attributes\n of the newly created directory entry.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_23symlink = {"symlink", (PyCFunction)__pyx_pw_6llfuse_10Operations_23symlink, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_22symlink}; static PyObject *__pyx_pw_6llfuse_10Operations_23symlink(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_target = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("symlink (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_target,&__pyx_n_s_ctx,0}; PyObject* values[5] = {0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("symlink", 1, 5, 5, 1); __PYX_ERR(0, 225, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("symlink", 1, 5, 5, 2); __PYX_ERR(0, 225, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_target)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("symlink", 1, 5, 5, 3); __PYX_ERR(0, 225, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("symlink", 1, 5, 5, 4); __PYX_ERR(0, 225, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "symlink") < 0)) __PYX_ERR(0, 225, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 5) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_target = values[3]; __pyx_v_ctx = values[4]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("symlink", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 225, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.symlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_22symlink(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_target, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_22symlink(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_target, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("symlink", 0); /* "src/operations.pxi":239 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def rename(self, parent_inode_old, name_old, parent_inode_new, */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 239, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 239, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 239, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 239, __pyx_L1_error) /* "src/operations.pxi":225 * raise FUSEError(errno.ENOSYS) * * def symlink(self, parent_inode, name, target, ctx): # <<<<<<<<<<<<<< * '''Create a symbolic link * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.symlink", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":241 * raise FUSEError(errno.ENOSYS) * * def rename(self, parent_inode_old, name_old, parent_inode_new, # <<<<<<<<<<<<<< * name_new, ctx): * '''Rename a directory entry. */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_25rename(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_24rename[] = "Operations.rename(self, parent_inode_old, name_old, parent_inode_new, name_new, ctx)\nRename a directory entry.\n\n This method must rename *name_old* in the directory with inode\n *parent_inode_old* to *name_new* in the directory with inode\n *parent_inode_new*. If *name_new* already exists, it should be\n overwritten. *ctx* will be a `RequestContext` instance.\n\n Let the inode associated with *name_old* in *parent_inode_old* be\n *inode_moved*, and the inode associated with *name_new* in\n *parent_inode_new* (if it exists) be called *inode_deref*.\n\n If *inode_deref* exists and has a non-zero lookup count, or if there are\n other directory entries referring to *inode_deref*), the file system\n must update only the directory entry for *name_new* to point to\n *inode_moved* instead of *inode_deref*. (Potential) removal of\n *inode_deref* (containing the previous contents of *name_new*) must be\n deferred to the `forget` method to be carried out when the lookup count\n reaches zero (and of course only if at that point there are no more\n directory entries associated with *inode_deref* either).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_25rename = {"rename", (PyCFunction)__pyx_pw_6llfuse_10Operations_25rename, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_24rename}; static PyObject *__pyx_pw_6llfuse_10Operations_25rename(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode_old = 0; CYTHON_UNUSED PyObject *__pyx_v_name_old = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode_new = 0; CYTHON_UNUSED PyObject *__pyx_v_name_new = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("rename (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode_old,&__pyx_n_s_name_old,&__pyx_n_s_parent_inode_new,&__pyx_n_s_name_new,&__pyx_n_s_ctx,0}; PyObject* values[6] = {0,0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5); case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode_old)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, 1); __PYX_ERR(0, 241, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name_old)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, 2); __PYX_ERR(0, 241, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode_new)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, 3); __PYX_ERR(0, 241, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name_new)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, 4); __PYX_ERR(0, 241, __pyx_L3_error) } case 5: if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, 5); __PYX_ERR(0, 241, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "rename") < 0)) __PYX_ERR(0, 241, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 6) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); values[5] = PyTuple_GET_ITEM(__pyx_args, 5); } __pyx_v_self = values[0]; __pyx_v_parent_inode_old = values[1]; __pyx_v_name_old = values[2]; __pyx_v_parent_inode_new = values[3]; __pyx_v_name_new = values[4]; __pyx_v_ctx = values[5]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("rename", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 241, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.rename", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_24rename(__pyx_self, __pyx_v_self, __pyx_v_parent_inode_old, __pyx_v_name_old, __pyx_v_parent_inode_new, __pyx_v_name_new, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_24rename(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode_old, CYTHON_UNUSED PyObject *__pyx_v_name_old, CYTHON_UNUSED PyObject *__pyx_v_parent_inode_new, CYTHON_UNUSED PyObject *__pyx_v_name_new, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("rename", 0); /* "src/operations.pxi":264 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def link(self, inode, new_parent_inode, new_name, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 264, __pyx_L1_error) /* "src/operations.pxi":241 * raise FUSEError(errno.ENOSYS) * * def rename(self, parent_inode_old, name_old, parent_inode_new, # <<<<<<<<<<<<<< * name_new, ctx): * '''Rename a directory entry. */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.rename", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":266 * raise FUSEError(errno.ENOSYS) * * def link(self, inode, new_parent_inode, new_name, ctx): # <<<<<<<<<<<<<< * '''Create directory entry *name* in *parent_inode* refering to *inode*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_27link(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_26link[] = "Operations.link(self, inode, new_parent_inode, new_name, ctx)\nCreate directory entry *name* in *parent_inode* refering to *inode*.\n\n *ctx* will be a `RequestContext` instance.\n\n The method must return an `EntryAttributes` instance with the\n attributes of the newly created directory entry.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_27link = {"link", (PyCFunction)__pyx_pw_6llfuse_10Operations_27link, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_26link}; static PyObject *__pyx_pw_6llfuse_10Operations_27link(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_new_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_new_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("link (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_new_parent_inode,&__pyx_n_s_new_name,&__pyx_n_s_ctx,0}; PyObject* values[5] = {0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("link", 1, 5, 5, 1); __PYX_ERR(0, 266, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_new_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("link", 1, 5, 5, 2); __PYX_ERR(0, 266, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_new_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("link", 1, 5, 5, 3); __PYX_ERR(0, 266, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("link", 1, 5, 5, 4); __PYX_ERR(0, 266, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "link") < 0)) __PYX_ERR(0, 266, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 5) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_new_parent_inode = values[2]; __pyx_v_new_name = values[3]; __pyx_v_ctx = values[4]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("link", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 266, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.link", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_26link(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_new_parent_inode, __pyx_v_new_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_26link(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_new_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_new_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("link", 0); /* "src/operations.pxi":278 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def open(self, inode, flags, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 278, __pyx_L1_error) /* "src/operations.pxi":266 * raise FUSEError(errno.ENOSYS) * * def link(self, inode, new_parent_inode, new_name, ctx): # <<<<<<<<<<<<<< * '''Create directory entry *name* in *parent_inode* refering to *inode*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.link", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":280 * raise FUSEError(errno.ENOSYS) * * def open(self, inode, flags, ctx): # <<<<<<<<<<<<<< * '''Open a inode *inode* with *flags*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_29open(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_28open[] = "Operations.open(self, inode, flags, ctx)\nOpen a inode *inode* with *flags*.\n\n *ctx* will be a `RequestContext` instance.\n\n *flags* will be a bitwise or of the open flags described in the\n :manpage:`open(2)` manpage and defined in the `os` module (with the\n exception of ``O_CREAT``, ``O_EXCL``, ``O_NOCTTY`` and ``O_TRUNC``)\n\n This method must return an integer file handle. The file handle will be\n passed to the `read`, `write`, `flush`, `fsync` and `release` methods to\n identify the open file.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_29open = {"open", (PyCFunction)__pyx_pw_6llfuse_10Operations_29open, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_28open}; static PyObject *__pyx_pw_6llfuse_10Operations_29open(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_flags = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("open (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_flags,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("open", 1, 4, 4, 1); __PYX_ERR(0, 280, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_flags)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("open", 1, 4, 4, 2); __PYX_ERR(0, 280, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("open", 1, 4, 4, 3); __PYX_ERR(0, 280, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "open") < 0)) __PYX_ERR(0, 280, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_flags = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("open", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 280, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.open", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_28open(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_flags, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_28open(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_flags, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("open", 0); /* "src/operations.pxi":294 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def read(self, fh, off, size): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 294, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 294, __pyx_L1_error) /* "src/operations.pxi":280 * raise FUSEError(errno.ENOSYS) * * def open(self, inode, flags, ctx): # <<<<<<<<<<<<<< * '''Open a inode *inode* with *flags*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.open", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":296 * raise FUSEError(errno.ENOSYS) * * def read(self, fh, off, size): # <<<<<<<<<<<<<< * '''Read *size* bytes from *fh* at position *off* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_31read(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_30read[] = "Operations.read(self, fh, off, size)\nRead *size* bytes from *fh* at position *off*\n\n *fh* will by an integer filehandle returned by a prior `open` or\n `create` call.\n\n This function should return exactly the number of bytes requested except\n on EOF or error, otherwise the rest of the data will be substituted with\n zeroes.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_31read = {"read", (PyCFunction)__pyx_pw_6llfuse_10Operations_31read, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_30read}; static PyObject *__pyx_pw_6llfuse_10Operations_31read(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_off = 0; CYTHON_UNUSED PyObject *__pyx_v_size = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("read (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,&__pyx_n_s_off,&__pyx_n_s_size,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("read", 1, 4, 4, 1); __PYX_ERR(0, 296, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_off)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("read", 1, 4, 4, 2); __PYX_ERR(0, 296, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_size)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("read", 1, 4, 4, 3); __PYX_ERR(0, 296, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "read") < 0)) __PYX_ERR(0, 296, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; __pyx_v_off = values[2]; __pyx_v_size = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("read", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 296, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.read", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_30read(__pyx_self, __pyx_v_self, __pyx_v_fh, __pyx_v_off, __pyx_v_size); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_30read(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off, CYTHON_UNUSED PyObject *__pyx_v_size) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("read", 0); /* "src/operations.pxi":307 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def write(self, fh, off, buf): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 307, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 307, __pyx_L1_error) /* "src/operations.pxi":296 * raise FUSEError(errno.ENOSYS) * * def read(self, fh, off, size): # <<<<<<<<<<<<<< * '''Read *size* bytes from *fh* at position *off* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.read", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":309 * raise FUSEError(errno.ENOSYS) * * def write(self, fh, off, buf): # <<<<<<<<<<<<<< * '''Write *buf* into *fh* at *off* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_33write(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_32write[] = "Operations.write(self, fh, off, buf)\nWrite *buf* into *fh* at *off*\n\n *fh* will by an integer filehandle returned by a prior `open` or\n `create` call.\n\n This method must returns the number of bytes written. However, uuless\n the file system has been mounted with the ``direct_io`` option, the file\n system *must* always write *all* the provided data (i.e., return\n ``len(buf)``).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_33write = {"write", (PyCFunction)__pyx_pw_6llfuse_10Operations_33write, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_32write}; static PyObject *__pyx_pw_6llfuse_10Operations_33write(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_off = 0; CYTHON_UNUSED PyObject *__pyx_v_buf = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("write (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,&__pyx_n_s_off,&__pyx_n_s_buf,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("write", 1, 4, 4, 1); __PYX_ERR(0, 309, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_off)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("write", 1, 4, 4, 2); __PYX_ERR(0, 309, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_buf)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("write", 1, 4, 4, 3); __PYX_ERR(0, 309, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "write") < 0)) __PYX_ERR(0, 309, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; __pyx_v_off = values[2]; __pyx_v_buf = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("write", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 309, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.write", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_32write(__pyx_self, __pyx_v_self, __pyx_v_fh, __pyx_v_off, __pyx_v_buf); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_32write(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off, CYTHON_UNUSED PyObject *__pyx_v_buf) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("write", 0); /* "src/operations.pxi":321 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def flush(self, fh): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 321, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 321, __pyx_L1_error) /* "src/operations.pxi":309 * raise FUSEError(errno.ENOSYS) * * def write(self, fh, off, buf): # <<<<<<<<<<<<<< * '''Write *buf* into *fh* at *off* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.write", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":323 * raise FUSEError(errno.ENOSYS) * * def flush(self, fh): # <<<<<<<<<<<<<< * '''Handle close() syscall. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_35flush(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_34flush[] = "Operations.flush(self, fh)\nHandle close() syscall.\n\n *fh* will by an integer filehandle returned by a prior `open` or\n `create` call.\n\n This method is called whenever a file descriptor is closed. It may be\n called multiple times for the same open file (e.g. if the file handle\n has been duplicated).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_35flush = {"flush", (PyCFunction)__pyx_pw_6llfuse_10Operations_35flush, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_34flush}; static PyObject *__pyx_pw_6llfuse_10Operations_35flush(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("flush (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("flush", 1, 2, 2, 1); __PYX_ERR(0, 323, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "flush") < 0)) __PYX_ERR(0, 323, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("flush", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 323, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.flush", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_34flush(__pyx_self, __pyx_v_self, __pyx_v_fh); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_34flush(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("flush", 0); /* "src/operations.pxi":334 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def release(self, fh): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 334, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 334, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 334, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 334, __pyx_L1_error) /* "src/operations.pxi":323 * raise FUSEError(errno.ENOSYS) * * def flush(self, fh): # <<<<<<<<<<<<<< * '''Handle close() syscall. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.flush", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":336 * raise FUSEError(errno.ENOSYS) * * def release(self, fh): # <<<<<<<<<<<<<< * '''Release open file * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_37release(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_36release[] = "Operations.release(self, fh)\nRelease open file\n\n This method will be called when the last file descriptor of *fh* has\n been closed, i.e. when the file is no longer opened by any client\n process.\n\n *fh* will by an integer filehandle returned by a prior `open` or\n `create` call. Once `release` has been called, no future requests for\n *fh* will be received (until the value is re-used in the return value of\n another `open` or `create` call).\n\n This method may return an error by raising `FUSEError`, but the error\n will be discarded because there is no corresponding client request.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_37release = {"release", (PyCFunction)__pyx_pw_6llfuse_10Operations_37release, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_36release}; static PyObject *__pyx_pw_6llfuse_10Operations_37release(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("release (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("release", 1, 2, 2, 1); __PYX_ERR(0, 336, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "release") < 0)) __PYX_ERR(0, 336, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("release", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 336, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.release", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_36release(__pyx_self, __pyx_v_self, __pyx_v_fh); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_36release(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("release", 0); /* "src/operations.pxi":352 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def fsync(self, fh, datasync): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 352, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 352, __pyx_L1_error) /* "src/operations.pxi":336 * raise FUSEError(errno.ENOSYS) * * def release(self, fh): # <<<<<<<<<<<<<< * '''Release open file * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.release", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":354 * raise FUSEError(errno.ENOSYS) * * def fsync(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open file *fh* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_39fsync(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_38fsync[] = "Operations.fsync(self, fh, datasync)\nFlush buffers for open file *fh*\n\n If *datasync* is true, only the file contents should be\n flushed (in contrast to the metadata about the file).\n\n *fh* will by an integer filehandle returned by a prior `open` or\n `create` call.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_39fsync = {"fsync", (PyCFunction)__pyx_pw_6llfuse_10Operations_39fsync, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_38fsync}; static PyObject *__pyx_pw_6llfuse_10Operations_39fsync(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_datasync = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("fsync (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,&__pyx_n_s_datasync,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("fsync", 1, 3, 3, 1); __PYX_ERR(0, 354, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_datasync)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("fsync", 1, 3, 3, 2); __PYX_ERR(0, 354, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fsync") < 0)) __PYX_ERR(0, 354, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; __pyx_v_datasync = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("fsync", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 354, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.fsync", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_38fsync(__pyx_self, __pyx_v_self, __pyx_v_fh, __pyx_v_datasync); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_38fsync(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_datasync) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("fsync", 0); /* "src/operations.pxi":364 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def opendir(self, inode, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 364, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 364, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 364, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 364, __pyx_L1_error) /* "src/operations.pxi":354 * raise FUSEError(errno.ENOSYS) * * def fsync(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open file *fh* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.fsync", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":366 * raise FUSEError(errno.ENOSYS) * * def opendir(self, inode, ctx): # <<<<<<<<<<<<<< * '''Open the directory with inode *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_41opendir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_40opendir[] = "Operations.opendir(self, inode, ctx)\nOpen the directory with inode *inode*\n\n *ctx* will be a `RequestContext` instance.\n\n This method should return an integer file handle. The file handle will\n be passed to the `readdir`, `fsyncdir` and `releasedir` methods to\n identify the directory.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_41opendir = {"opendir", (PyCFunction)__pyx_pw_6llfuse_10Operations_41opendir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_40opendir}; static PyObject *__pyx_pw_6llfuse_10Operations_41opendir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("opendir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_ctx,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("opendir", 1, 3, 3, 1); __PYX_ERR(0, 366, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("opendir", 1, 3, 3, 2); __PYX_ERR(0, 366, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "opendir") < 0)) __PYX_ERR(0, 366, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_ctx = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("opendir", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 366, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.opendir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_40opendir(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_40opendir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("opendir", 0); /* "src/operations.pxi":376 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 376, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 376, __pyx_L1_error) /* "src/operations.pxi":366 * raise FUSEError(errno.ENOSYS) * * def opendir(self, inode, ctx): # <<<<<<<<<<<<<< * '''Open the directory with inode *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.opendir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":379 * * * def readdir(self, fh, off): # <<<<<<<<<<<<<< * '''Read entries in open directory *fh*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_43readdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_42readdir[] = "Operations.readdir(self, fh, off)\nRead entries in open directory *fh*.\n\n This method should return an iterator over the contents of directory\n *fh* (as returned by a prior `opendir` call), starting at the entry\n identified by *off*.\n\n The iterator must yield tuples of the form :samp:`({name}, {attr},\n {next_})`, where *attr* is an `EntryAttributes` instance and *next_*\n gives an offset that can be passed as *off* to start a successive\n `readdir` call at the right position.\n\n Iteration may be stopped as soon as enough elements have been\n retrieved. The method should be prepared for this case.\n\n If entries are added or removed during a `readdir` cycle, they may or\n may not be returned. However, they must not cause other entries to be\n skipped or returned more than once.\n\n :file:`.` and :file:`..` entries may be included but are not required.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_43readdir = {"readdir", (PyCFunction)__pyx_pw_6llfuse_10Operations_43readdir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_42readdir}; static PyObject *__pyx_pw_6llfuse_10Operations_43readdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_off = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("readdir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,&__pyx_n_s_off,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("readdir", 1, 3, 3, 1); __PYX_ERR(0, 379, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_off)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("readdir", 1, 3, 3, 2); __PYX_ERR(0, 379, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "readdir") < 0)) __PYX_ERR(0, 379, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; __pyx_v_off = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("readdir", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 379, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.readdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_42readdir(__pyx_self, __pyx_v_self, __pyx_v_fh, __pyx_v_off); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_42readdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_off) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("readdir", 0); /* "src/operations.pxi":401 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def releasedir(self, fh): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 401, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 401, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 401, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 401, __pyx_L1_error) /* "src/operations.pxi":379 * * * def readdir(self, fh, off): # <<<<<<<<<<<<<< * '''Read entries in open directory *fh*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.readdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":403 * raise FUSEError(errno.ENOSYS) * * def releasedir(self, fh): # <<<<<<<<<<<<<< * '''Release open directory * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_45releasedir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_44releasedir[] = "Operations.releasedir(self, fh)\nRelease open directory\n\n This method will be called exactly once for each `opendir` call. After\n *fh* has been released, no further `readdir` requests will be received\n for it (until it is opened again with `opendir`).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_45releasedir = {"releasedir", (PyCFunction)__pyx_pw_6llfuse_10Operations_45releasedir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_44releasedir}; static PyObject *__pyx_pw_6llfuse_10Operations_45releasedir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("releasedir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("releasedir", 1, 2, 2, 1); __PYX_ERR(0, 403, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "releasedir") < 0)) __PYX_ERR(0, 403, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("releasedir", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 403, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_44releasedir(__pyx_self, __pyx_v_self, __pyx_v_fh); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_44releasedir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("releasedir", 0); /* "src/operations.pxi":411 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def fsyncdir(self, fh, datasync): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 411, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 411, __pyx_L1_error) /* "src/operations.pxi":403 * raise FUSEError(errno.ENOSYS) * * def releasedir(self, fh): # <<<<<<<<<<<<<< * '''Release open directory * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":413 * raise FUSEError(errno.ENOSYS) * * def fsyncdir(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open directory *fh* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_47fsyncdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_46fsyncdir[] = "Operations.fsyncdir(self, fh, datasync)\nFlush buffers for open directory *fh*\n\n If *datasync* is true, only the directory contents should be\n flushed (in contrast to metadata about the directory itself).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_47fsyncdir = {"fsyncdir", (PyCFunction)__pyx_pw_6llfuse_10Operations_47fsyncdir, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_46fsyncdir}; static PyObject *__pyx_pw_6llfuse_10Operations_47fsyncdir(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_fh = 0; CYTHON_UNUSED PyObject *__pyx_v_datasync = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("fsyncdir (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_fh,&__pyx_n_s_datasync,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_fh)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("fsyncdir", 1, 3, 3, 1); __PYX_ERR(0, 413, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_datasync)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("fsyncdir", 1, 3, 3, 2); __PYX_ERR(0, 413, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "fsyncdir") < 0)) __PYX_ERR(0, 413, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_fh = values[1]; __pyx_v_datasync = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("fsyncdir", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 413, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_46fsyncdir(__pyx_self, __pyx_v_self, __pyx_v_fh, __pyx_v_datasync); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_46fsyncdir(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_fh, CYTHON_UNUSED PyObject *__pyx_v_datasync) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("fsyncdir", 0); /* "src/operations.pxi":420 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def statfs(self, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 420, __pyx_L1_error) /* "src/operations.pxi":413 * raise FUSEError(errno.ENOSYS) * * def fsyncdir(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open directory *fh* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":422 * raise FUSEError(errno.ENOSYS) * * def statfs(self, ctx): # <<<<<<<<<<<<<< * '''Get file system statistics * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_49statfs(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_48statfs[] = "Operations.statfs(self, ctx)\nGet file system statistics\n\n *ctx* will be a `RequestContext` instance.\n\n The method must return an appropriately filled `StatvfsData` instance.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_49statfs = {"statfs", (PyCFunction)__pyx_pw_6llfuse_10Operations_49statfs, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_48statfs}; static PyObject *__pyx_pw_6llfuse_10Operations_49statfs(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("statfs (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_ctx,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("statfs", 1, 2, 2, 1); __PYX_ERR(0, 422, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "statfs") < 0)) __PYX_ERR(0, 422, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_self = values[0]; __pyx_v_ctx = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("statfs", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 422, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.statfs", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_48statfs(__pyx_self, __pyx_v_self, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_48statfs(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("statfs", 0); /* "src/operations.pxi":430 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def stacktrace(self): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 430, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 430, __pyx_L1_error) /* "src/operations.pxi":422 * raise FUSEError(errno.ENOSYS) * * def statfs(self, ctx): # <<<<<<<<<<<<<< * '''Get file system statistics * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.statfs", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":432 * raise FUSEError(errno.ENOSYS) * * def stacktrace(self): # <<<<<<<<<<<<<< * '''Asynchronous debugging * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_51stacktrace(PyObject *__pyx_self, PyObject *__pyx_v_self); /*proto*/ static char __pyx_doc_6llfuse_10Operations_50stacktrace[] = "Operations.stacktrace(self)\nAsynchronous debugging\n\n This method will be called when the ``fuse_stacktrace`` extended\n attribute is set on the mountpoint. It will be called without holding\n the global lock. The default implementation logs the current stack trace\n of every running Python thread. This can be quite useful to debug file\n system deadlocks.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_51stacktrace = {"stacktrace", (PyCFunction)__pyx_pw_6llfuse_10Operations_51stacktrace, METH_O, __pyx_doc_6llfuse_10Operations_50stacktrace}; static PyObject *__pyx_pw_6llfuse_10Operations_51stacktrace(PyObject *__pyx_self, PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("stacktrace (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_10Operations_50stacktrace(__pyx_self, ((PyObject *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_50stacktrace(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self) { PyObject *__pyx_v_sys = NULL; PyObject *__pyx_v_traceback = NULL; PyObject *__pyx_v_code = NULL; PyObject *__pyx_v_threadId = NULL; PyObject *__pyx_v_frame = NULL; PyObject *__pyx_v_filename = NULL; PyObject *__pyx_v_lineno = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_line = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; Py_ssize_t __pyx_t_3; int __pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; int __pyx_t_8; int __pyx_t_9; PyObject *__pyx_t_10 = NULL; Py_ssize_t __pyx_t_11; PyObject *(*__pyx_t_12)(PyObject *); PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; PyObject *(*__pyx_t_16)(PyObject *); int __pyx_t_17; __Pyx_RefNannySetupContext("stacktrace", 0); /* "src/operations.pxi":442 * ''' * * import sys # <<<<<<<<<<<<<< * import traceback * */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_sys = __pyx_t_1; __pyx_t_1 = 0; /* "src/operations.pxi":443 * * import sys * import traceback # <<<<<<<<<<<<<< * * code = list() */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_traceback, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_traceback = __pyx_t_1; __pyx_t_1 = 0; /* "src/operations.pxi":445 * import traceback * * code = list() # <<<<<<<<<<<<<< * for threadId, frame in sys._current_frames().items(): * code.append("\n# ThreadID: %s" % threadId) */ __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 445, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_code = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; /* "src/operations.pxi":446 * * code = list() * for threadId, frame in sys._current_frames().items(): # <<<<<<<<<<<<<< * code.append("\n# ThreadID: %s" % threadId) * for filename, lineno, name, line in traceback.extract_stack(frame): */ __pyx_t_2 = 0; __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_sys, __pyx_n_s_current_frames); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (__pyx_t_7) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 446, __pyx_L1_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_5 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 446, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (unlikely(__pyx_t_5 == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "items"); __PYX_ERR(0, 446, __pyx_L1_error) } __pyx_t_6 = __Pyx_dict_iterator(__pyx_t_5, 0, __pyx_n_s_items, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = __pyx_t_6; __pyx_t_6 = 0; while (1) { __pyx_t_8 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_3, &__pyx_t_2, &__pyx_t_6, &__pyx_t_5, NULL, __pyx_t_4); if (unlikely(__pyx_t_8 == 0)) break; if (unlikely(__pyx_t_8 == -1)) __PYX_ERR(0, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_5); __Pyx_XDECREF_SET(__pyx_v_threadId, __pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF_SET(__pyx_v_frame, __pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":447 * code = list() * for threadId, frame in sys._current_frames().items(): * code.append("\n# ThreadID: %s" % threadId) # <<<<<<<<<<<<<< * for filename, lineno, name, line in traceback.extract_stack(frame): * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) */ __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_ThreadID_s, __pyx_v_threadId); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 447, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_code, __pyx_t_5); if (unlikely(__pyx_t_9 == -1)) __PYX_ERR(0, 447, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":448 * for threadId, frame in sys._current_frames().items(): * code.append("\n# ThreadID: %s" % threadId) * for filename, lineno, name, line in traceback.extract_stack(frame): # <<<<<<<<<<<<<< * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) * if line: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_traceback, __pyx_n_s_extract_stack); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_7) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_frame); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_v_frame}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_v_frame}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { __pyx_t_10 = PyTuple_New(1+1); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_7); __pyx_t_7 = NULL; __Pyx_INCREF(__pyx_v_frame); __Pyx_GIVEREF(__pyx_v_frame); PyTuple_SET_ITEM(__pyx_t_10, 0+1, __pyx_v_frame); __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_10, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) { __pyx_t_6 = __pyx_t_5; __Pyx_INCREF(__pyx_t_6); __pyx_t_11 = 0; __pyx_t_12 = NULL; } else { __pyx_t_11 = -1; __pyx_t_6 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_12 = Py_TYPE(__pyx_t_6)->tp_iternext; if (unlikely(!__pyx_t_12)) __PYX_ERR(0, 448, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; for (;;) { if (likely(!__pyx_t_12)) { if (likely(PyList_CheckExact(__pyx_t_6))) { if (__pyx_t_11 >= PyList_GET_SIZE(__pyx_t_6)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_5 = PyList_GET_ITEM(__pyx_t_6, __pyx_t_11); __Pyx_INCREF(__pyx_t_5); __pyx_t_11++; if (unlikely(0 < 0)) __PYX_ERR(0, 448, __pyx_L1_error) #else __pyx_t_5 = PySequence_ITEM(__pyx_t_6, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } else { if (__pyx_t_11 >= PyTuple_GET_SIZE(__pyx_t_6)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_6, __pyx_t_11); __Pyx_INCREF(__pyx_t_5); __pyx_t_11++; if (unlikely(0 < 0)) __PYX_ERR(0, 448, __pyx_L1_error) #else __pyx_t_5 = PySequence_ITEM(__pyx_t_6, __pyx_t_11); __pyx_t_11++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); #endif } } else { __pyx_t_5 = __pyx_t_12(__pyx_t_6); if (unlikely(!__pyx_t_5)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(0, 448, __pyx_L1_error) } break; } __Pyx_GOTREF(__pyx_t_5); } if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) { PyObject* sequence = __pyx_t_5; #if !CYTHON_COMPILING_IN_PYPY Py_ssize_t size = Py_SIZE(sequence); #else Py_ssize_t size = PySequence_Size(sequence); #endif if (unlikely(size != 4)) { if (size > 4) __Pyx_RaiseTooManyValuesError(4); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); __PYX_ERR(0, 448, __pyx_L1_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { __pyx_t_10 = PyTuple_GET_ITEM(sequence, 0); __pyx_t_7 = PyTuple_GET_ITEM(sequence, 1); __pyx_t_13 = PyTuple_GET_ITEM(sequence, 2); __pyx_t_14 = PyTuple_GET_ITEM(sequence, 3); } else { __pyx_t_10 = PyList_GET_ITEM(sequence, 0); __pyx_t_7 = PyList_GET_ITEM(sequence, 1); __pyx_t_13 = PyList_GET_ITEM(sequence, 2); __pyx_t_14 = PyList_GET_ITEM(sequence, 3); } __Pyx_INCREF(__pyx_t_10); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(__pyx_t_14); #else { Py_ssize_t i; PyObject** temps[4] = {&__pyx_t_10,&__pyx_t_7,&__pyx_t_13,&__pyx_t_14}; for (i=0; i < 4; i++) { PyObject* item = PySequence_ITEM(sequence, i); if (unlikely(!item)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(item); *(temps[i]) = item; } } #endif __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else { Py_ssize_t index = -1; PyObject** temps[4] = {&__pyx_t_10,&__pyx_t_7,&__pyx_t_13,&__pyx_t_14}; __pyx_t_15 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_15)) __PYX_ERR(0, 448, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_16 = Py_TYPE(__pyx_t_15)->tp_iternext; for (index=0; index < 4; index++) { PyObject* item = __pyx_t_16(__pyx_t_15); if (unlikely(!item)) goto __pyx_L7_unpacking_failed; __Pyx_GOTREF(item); *(temps[index]) = item; } if (__Pyx_IternextUnpackEndCheck(__pyx_t_16(__pyx_t_15), 4) < 0) __PYX_ERR(0, 448, __pyx_L1_error) __pyx_t_16 = NULL; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L8_unpacking_done; __pyx_L7_unpacking_failed:; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __pyx_t_16 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); __PYX_ERR(0, 448, __pyx_L1_error) __pyx_L8_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_filename, __pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF_SET(__pyx_v_lineno, __pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF_SET(__pyx_v_line, __pyx_t_14); __pyx_t_14 = 0; /* "src/operations.pxi":449 * code.append("\n# ThreadID: %s" % threadId) * for filename, lineno, name, line in traceback.extract_stack(frame): * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) # <<<<<<<<<<<<<< * if line: * code.append(" %s" % (line.strip())) */ __pyx_t_14 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_t_14, __pyx_n_s_path); if (unlikely(!__pyx_t_13)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __pyx_t_14 = __Pyx_PyObject_GetAttrStr(__pyx_t_13, __pyx_n_s_basename); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __pyx_t_13 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_14))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_14); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_14); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_14, function); } } if (!__pyx_t_13) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_14, __pyx_v_filename); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_14)) { PyObject *__pyx_temp[2] = {__pyx_t_13, __pyx_v_filename}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_14, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_14)) { PyObject *__pyx_temp[2] = {__pyx_t_13, __pyx_v_filename}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_14, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_5); } else #endif { __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_13); __pyx_t_13 = NULL; __Pyx_INCREF(__pyx_v_filename); __Pyx_GIVEREF(__pyx_v_filename); PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_v_filename); __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_14, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __pyx_t_14 = PyTuple_New(3); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_5); __Pyx_INCREF(__pyx_v_lineno); __Pyx_GIVEREF(__pyx_v_lineno); PyTuple_SET_ITEM(__pyx_t_14, 1, __pyx_v_lineno); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_14, 2, __pyx_v_name); __pyx_t_5 = 0; __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_s_d_in_s, __pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_code, __pyx_t_5); if (unlikely(__pyx_t_9 == -1)) __PYX_ERR(0, 449, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":450 * for filename, lineno, name, line in traceback.extract_stack(frame): * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) * if line: # <<<<<<<<<<<<<< * code.append(" %s" % (line.strip())) * */ __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_v_line); if (unlikely(__pyx_t_17 < 0)) __PYX_ERR(0, 450, __pyx_L1_error) if (__pyx_t_17) { /* "src/operations.pxi":451 * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) * if line: * code.append(" %s" % (line.strip())) # <<<<<<<<<<<<<< * * log.error("\n".join(code)) */ __pyx_t_14 = __Pyx_PyObject_GetAttrStr(__pyx_v_line, __pyx_n_s_strip); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 451, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_14))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_14); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_14); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_14, function); } } if (__pyx_t_7) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_14, __pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 451, __pyx_L1_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_5 = __Pyx_PyObject_CallNoArg(__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 451, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __pyx_t_14 = PyUnicode_Format(__pyx_kp_u_s, __pyx_t_5); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 451, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_code, __pyx_t_14); if (unlikely(__pyx_t_9 == -1)) __PYX_ERR(0, 451, __pyx_L1_error) __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/operations.pxi":450 * for filename, lineno, name, line in traceback.extract_stack(frame): * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) * if line: # <<<<<<<<<<<<<< * code.append(" %s" % (line.strip())) * */ } /* "src/operations.pxi":448 * for threadId, frame in sys._current_frames().items(): * code.append("\n# ThreadID: %s" % threadId) * for filename, lineno, name, line in traceback.extract_stack(frame): # <<<<<<<<<<<<<< * code.append('%s:%d, in %s' % (os.path.basename(filename), lineno, name)) * if line: */ } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/operations.pxi":453 * code.append(" %s" % (line.strip())) * * log.error("\n".join(code)) # <<<<<<<<<<<<<< * * def setxattr(self, inode, name, value, ctx): */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_14 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_14)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = PyUnicode_Join(__pyx_kp_u_, __pyx_v_code); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_14))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_14); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_14); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_14, function); } } if (!__pyx_t_5) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_14, __pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_1); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_14)) { PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_6}; __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_14, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_14)) { PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_t_6}; __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_14, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_14, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 453, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/operations.pxi":432 * raise FUSEError(errno.ENOSYS) * * def stacktrace(self): # <<<<<<<<<<<<<< * '''Asynchronous debugging * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_10); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_14); __Pyx_XDECREF(__pyx_t_15); __Pyx_AddTraceback("llfuse.Operations.stacktrace", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_sys); __Pyx_XDECREF(__pyx_v_traceback); __Pyx_XDECREF(__pyx_v_code); __Pyx_XDECREF(__pyx_v_threadId); __Pyx_XDECREF(__pyx_v_frame); __Pyx_XDECREF(__pyx_v_filename); __Pyx_XDECREF(__pyx_v_lineno); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_line); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":455 * log.error("\n".join(code)) * * def setxattr(self, inode, name, value, ctx): # <<<<<<<<<<<<<< * '''Set extended attribute *name* of *inode* to *value*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_53setxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_52setxattr[] = "Operations.setxattr(self, inode, name, value, ctx)\nSet extended attribute *name* of *inode* to *value*.\n\n *ctx* will be a `RequestContext` instance.\n\n The attribute may or may not exist already. Both *name* and *value* will\n be of type `bytes`. *name* is guaranteed not to contain zero-bytes\n (``\\0``).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_53setxattr = {"setxattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_53setxattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_52setxattr}; static PyObject *__pyx_pw_6llfuse_10Operations_53setxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_value = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("setxattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_name,&__pyx_n_s_value,&__pyx_n_s_ctx,0}; PyObject* values[5] = {0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 1, 5, 5, 1); __PYX_ERR(0, 455, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 1, 5, 5, 2); __PYX_ERR(0, 455, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 1, 5, 5, 3); __PYX_ERR(0, 455, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 1, 5, 5, 4); __PYX_ERR(0, 455, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "setxattr") < 0)) __PYX_ERR(0, 455, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 5) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_value = values[3]; __pyx_v_ctx = values[4]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("setxattr", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 455, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_52setxattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_name, __pyx_v_value, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_52setxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_value, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("setxattr", 0); /* "src/operations.pxi":465 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def getxattr(self, inode, name, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 465, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 465, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 465, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 465, __pyx_L1_error) /* "src/operations.pxi":455 * log.error("\n".join(code)) * * def setxattr(self, inode, name, value, ctx): # <<<<<<<<<<<<<< * '''Set extended attribute *name* of *inode* to *value*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":467 * raise FUSEError(errno.ENOSYS) * * def getxattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Return extended attribute *name* of *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_55getxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_54getxattr[] = "Operations.getxattr(self, inode, name, ctx)\nReturn extended attribute *name* of *inode*\n\n *ctx* will be a `RequestContext` instance.\n\n If the attribute does not exist, the method must raise `FUSEError` with\n an error code of `ENOATTR`. *name* will be of type `bytes`, but is\n guaranteed not to contain zero-bytes (``\\0``).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_55getxattr = {"getxattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_55getxattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_54getxattr}; static PyObject *__pyx_pw_6llfuse_10Operations_55getxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("getxattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_name,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getxattr", 1, 4, 4, 1); __PYX_ERR(0, 467, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getxattr", 1, 4, 4, 2); __PYX_ERR(0, 467, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getxattr", 1, 4, 4, 3); __PYX_ERR(0, 467, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getxattr") < 0)) __PYX_ERR(0, 467, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("getxattr", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 467, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_54getxattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_54getxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("getxattr", 0); /* "src/operations.pxi":477 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def listxattr(self, inode, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 477, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 477, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 477, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 477, __pyx_L1_error) /* "src/operations.pxi":467 * raise FUSEError(errno.ENOSYS) * * def getxattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Return extended attribute *name* of *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":479 * raise FUSEError(errno.ENOSYS) * * def listxattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get list of extended attributes for *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_57listxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_56listxattr[] = "Operations.listxattr(self, inode, ctx)\nGet list of extended attributes for *inode*\n\n *ctx* will be a `RequestContext` instance.\n\n This method must return an iterator over a sequence of `bytes` objects.\n The objects must not to include zero-bytes (``\\0``).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_57listxattr = {"listxattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_57listxattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_56listxattr}; static PyObject *__pyx_pw_6llfuse_10Operations_57listxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("listxattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_ctx,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("listxattr", 1, 3, 3, 1); __PYX_ERR(0, 479, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("listxattr", 1, 3, 3, 2); __PYX_ERR(0, 479, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "listxattr") < 0)) __PYX_ERR(0, 479, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_ctx = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("listxattr", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 479, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_56listxattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_56listxattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("listxattr", 0); /* "src/operations.pxi":488 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def removexattr(self, inode, name, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 488, __pyx_L1_error) /* "src/operations.pxi":479 * raise FUSEError(errno.ENOSYS) * * def listxattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get list of extended attributes for *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":490 * raise FUSEError(errno.ENOSYS) * * def removexattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove extended attribute *name* of *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_59removexattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_58removexattr[] = "Operations.removexattr(self, inode, name, ctx)\nRemove extended attribute *name* of *inode*\n\n *ctx* will be a `RequestContext` instance.\n\n If the attribute does not exist, the method must raise `FUSEError` with\n an error code of `ENOATTR`. *name* will be of type `bytes`, but is\n guaranteed not to contain zero-bytes (``\\0``).\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_59removexattr = {"removexattr", (PyCFunction)__pyx_pw_6llfuse_10Operations_59removexattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_58removexattr}; static PyObject *__pyx_pw_6llfuse_10Operations_59removexattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("removexattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_name,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("removexattr", 1, 4, 4, 1); __PYX_ERR(0, 490, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("removexattr", 1, 4, 4, 2); __PYX_ERR(0, 490, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("removexattr", 1, 4, 4, 3); __PYX_ERR(0, 490, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "removexattr") < 0)) __PYX_ERR(0, 490, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("removexattr", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 490, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_58removexattr(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_name, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_58removexattr(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("removexattr", 0); /* "src/operations.pxi":500 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 500, __pyx_L1_error) /* "src/operations.pxi":490 * raise FUSEError(errno.ENOSYS) * * def removexattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove extended attribute *name* of *inode* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":503 * * * def access(self, inode, mode, ctx): # <<<<<<<<<<<<<< * '''Check if requesting process has *mode* rights on *inode*. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_61access(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_60access[] = "Operations.access(self, inode, mode, ctx)\nCheck if requesting process has *mode* rights on *inode*.\n\n *ctx* will be a `RequestContext` instance.\n\n The method must return a boolean value.\n\n If the ``default_permissions`` mount option is given, this method is not\n called.\n\n When implementing this method, the `get_sup_groups` function may be\n useful.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_61access = {"access", (PyCFunction)__pyx_pw_6llfuse_10Operations_61access, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_60access}; static PyObject *__pyx_pw_6llfuse_10Operations_61access(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_mode = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("access (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_inode,&__pyx_n_s_mode,&__pyx_n_s_ctx,0}; PyObject* values[4] = {0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("access", 1, 4, 4, 1); __PYX_ERR(0, 503, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_mode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("access", 1, 4, 4, 2); __PYX_ERR(0, 503, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("access", 1, 4, 4, 3); __PYX_ERR(0, 503, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "access") < 0)) __PYX_ERR(0, 503, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 4) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); } __pyx_v_self = values[0]; __pyx_v_inode = values[1]; __pyx_v_mode = values[2]; __pyx_v_ctx = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("access", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 503, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.access", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_60access(__pyx_self, __pyx_v_self, __pyx_v_inode, __pyx_v_mode, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_60access(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_inode, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("access", 0); /* "src/operations.pxi":517 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< * * def create(self, parent_inode, name, mode, flags, ctx): */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 517, __pyx_L1_error) /* "src/operations.pxi":503 * * * def access(self, inode, mode, ctx): # <<<<<<<<<<<<<< * '''Check if requesting process has *mode* rights on *inode*. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.access", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/operations.pxi":519 * raise FUSEError(errno.ENOSYS) * * def create(self, parent_inode, name, mode, flags, ctx): # <<<<<<<<<<<<<< * '''Create a file with permissions *mode* and open it with *flags* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_10Operations_63create(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10Operations_62create[] = "Operations.create(self, parent_inode, name, mode, flags, ctx)\nCreate a file with permissions *mode* and open it with *flags*\n\n *ctx* will be a `RequestContext` instance.\n\n The method must return a tuple of the form *(fh, attr)*, where *fh* is a\n file handle like the one returned by `open` and *attr* is an\n `EntryAttributes` instance with the attributes of the newly created\n directory entry.\n\n (Successful) execution of this handler increases the lookup count for\n the returned inode by one.\n "; static PyMethodDef __pyx_mdef_6llfuse_10Operations_63create = {"create", (PyCFunction)__pyx_pw_6llfuse_10Operations_63create, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10Operations_62create}; static PyObject *__pyx_pw_6llfuse_10Operations_63create(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_self = 0; CYTHON_UNUSED PyObject *__pyx_v_parent_inode = 0; CYTHON_UNUSED PyObject *__pyx_v_name = 0; CYTHON_UNUSED PyObject *__pyx_v_mode = 0; CYTHON_UNUSED PyObject *__pyx_v_flags = 0; CYTHON_UNUSED PyObject *__pyx_v_ctx = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("create (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_self,&__pyx_n_s_parent_inode,&__pyx_n_s_name,&__pyx_n_s_mode,&__pyx_n_s_flags,&__pyx_n_s_ctx,0}; PyObject* values[6] = {0,0,0,0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5); case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4); case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_self)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_parent_inode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, 1); __PYX_ERR(0, 519, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, 2); __PYX_ERR(0, 519, __pyx_L3_error) } case 3: if (likely((values[3] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_mode)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, 3); __PYX_ERR(0, 519, __pyx_L3_error) } case 4: if (likely((values[4] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_flags)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, 4); __PYX_ERR(0, 519, __pyx_L3_error) } case 5: if (likely((values[5] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ctx)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, 5); __PYX_ERR(0, 519, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "create") < 0)) __PYX_ERR(0, 519, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 6) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[3] = PyTuple_GET_ITEM(__pyx_args, 3); values[4] = PyTuple_GET_ITEM(__pyx_args, 4); values[5] = PyTuple_GET_ITEM(__pyx_args, 5); } __pyx_v_self = values[0]; __pyx_v_parent_inode = values[1]; __pyx_v_name = values[2]; __pyx_v_mode = values[3]; __pyx_v_flags = values[4]; __pyx_v_ctx = values[5]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("create", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 519, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Operations.create", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10Operations_62create(__pyx_self, __pyx_v_self, __pyx_v_parent_inode, __pyx_v_name, __pyx_v_mode, __pyx_v_flags, __pyx_v_ctx); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_10Operations_62create(CYTHON_UNUSED PyObject *__pyx_self, CYTHON_UNUSED PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_parent_inode, CYTHON_UNUSED PyObject *__pyx_v_name, CYTHON_UNUSED PyObject *__pyx_v_mode, CYTHON_UNUSED PyObject *__pyx_v_flags, CYTHON_UNUSED PyObject *__pyx_v_ctx) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("create", 0); /* "src/operations.pxi":533 * ''' * * raise FUSEError(errno.ENOSYS) # <<<<<<<<<<<<<< */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOSYS); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(0, 533, __pyx_L1_error) /* "src/operations.pxi":519 * raise FUSEError(errno.ENOSYS) * * def create(self, parent_inode, name, mode, flags, ctx): # <<<<<<<<<<<<<< * '''Create a file with permissions *mode* and open it with *flags* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Operations.create", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/handlers.pxi":13 * ''' * * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: # <<<<<<<<<<<<<< * try: * with lock: */ static void __pyx_f_6llfuse_fuse_init(CYTHON_UNUSED void *__pyx_v_userdata, CYTHON_UNUSED struct fuse_conn_info *__pyx_v_conn) { __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; int __pyx_t_14; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_init", 0); /* "src/handlers.pxi":14 * * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.init() */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":15 * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.init() * except: */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 15, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 15, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 15, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 15, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 15, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":16 * try: * with lock: * operations.init() # <<<<<<<<<<<<<< * except: * handle_exc(NULL) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_init); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 16, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (__pyx_t_7) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 16, __pyx_L17_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 16, __pyx_L17_error) } __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":15 * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.init() * except: */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_init", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(1, 15, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 15, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 15, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (__pyx_t_13 < 0) __PYX_ERR(1, 15, __pyx_L19_except_error) __pyx_t_14 = ((!(__pyx_t_13 != 0)) != 0); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_7); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_7 = 0; __PYX_ERR(1, 15, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__2, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 15, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":14 * * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.init() */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":17 * with lock: * operations.init() * except: # <<<<<<<<<<<<<< * handle_exc(NULL) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_init", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 17, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); /* "src/handlers.pxi":18 * operations.init() * except: * handle_exc(NULL) # <<<<<<<<<<<<<< * * cdef void fuse_destroy (void *userdata) with gil: */ __pyx_f_6llfuse_handle_exc(NULL); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":14 * * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.init() */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":13 * ''' * * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: # <<<<<<<<<<<<<< * try: * with lock: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_WriteUnraisable("llfuse.fuse_init", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":20 * handle_exc(NULL) * * cdef void fuse_destroy (void *userdata) with gil: # <<<<<<<<<<<<<< * global exc_info * try: */ static void __pyx_f_6llfuse_fuse_destroy(CYTHON_UNUSED void *__pyx_v_userdata) { __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_destroy", 0); /* "src/handlers.pxi":22 * cdef void fuse_destroy (void *userdata) with gil: * global exc_info * try: # <<<<<<<<<<<<<< * with lock: * operations.destroy() */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":23 * global exc_info * try: * with lock: # <<<<<<<<<<<<<< * operations.destroy() * except: */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 23, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 23, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 23, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 23, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 23, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":24 * try: * with lock: * operations.destroy() # <<<<<<<<<<<<<< * except: * if not exc_info: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_destroy); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 24, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (__pyx_t_7) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 24, __pyx_L17_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 24, __pyx_L17_error) } __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":23 * global exc_info * try: * with lock: # <<<<<<<<<<<<<< * operations.destroy() * except: */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_destroy", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(1, 23, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 23, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 23, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (__pyx_t_13 < 0) __PYX_ERR(1, 23, __pyx_L19_except_error) __pyx_t_14 = ((!(__pyx_t_13 != 0)) != 0); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_7); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_7 = 0; __PYX_ERR(1, 23, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__3, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 23, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":22 * cdef void fuse_destroy (void *userdata) with gil: * global exc_info * try: # <<<<<<<<<<<<<< * with lock: * operations.destroy() */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":25 * with lock: * operations.destroy() * except: # <<<<<<<<<<<<<< * if not exc_info: * exc_info = sys.exc_info() */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_destroy", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 25, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); /* "src/handlers.pxi":26 * operations.destroy() * except: * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * else: */ __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_v_6llfuse_exc_info); if (unlikely(__pyx_t_14 < 0)) __PYX_ERR(1, 26, __pyx_L5_except_error) __pyx_t_13 = ((!__pyx_t_14) != 0); if (__pyx_t_13) { /* "src/handlers.pxi":27 * except: * if not exc_info: * exc_info = sys.exc_info() # <<<<<<<<<<<<<< * else: * log.exception('Exception after kill:') */ __pyx_t_15 = __Pyx_GetModuleGlobalName(__pyx_n_s_sys); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 27, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_15, __pyx_n_s_exc_info); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 27, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __pyx_t_15 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_16))) { __pyx_t_15 = PyMethod_GET_SELF(__pyx_t_16); if (likely(__pyx_t_15)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_16); __Pyx_INCREF(__pyx_t_15); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_16, function); } } if (__pyx_t_15) { __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_t_16, __pyx_t_15); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 27, __pyx_L5_except_error) __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } else { __pyx_t_8 = __Pyx_PyObject_CallNoArg(__pyx_t_16); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 27, __pyx_L5_except_error) } __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_8); __pyx_t_8 = 0; /* "src/handlers.pxi":26 * operations.destroy() * except: * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * else: */ goto __pyx_L31; } /* "src/handlers.pxi":29 * exc_info = sys.exc_info() * else: * log.exception('Exception after kill:') # <<<<<<<<<<<<<< * * cdef void fuse_lookup (fuse_req_t req, fuse_ino_t parent, */ /*else*/ { __pyx_t_8 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 29, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_exception); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 29, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_16, __pyx_tuple__4, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 29, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __pyx_L31:; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":22 * cdef void fuse_destroy (void *userdata) with gil: * global exc_info * try: # <<<<<<<<<<<<<< * with lock: * operations.destroy() */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":20 * handle_exc(NULL) * * cdef void fuse_destroy (void *userdata) with gil: # <<<<<<<<<<<<<< * global exc_info * try: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_15); __Pyx_XDECREF(__pyx_t_16); __Pyx_WriteUnraisable("llfuse.fuse_destroy", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":31 * log.exception('Exception after kill:') * * cdef void fuse_lookup (fuse_req_t req, fuse_ino_t parent, # <<<<<<<<<<<<<< * const_char *c_name) with gil: * cdef EntryAttributes entry */ static void __pyx_f_6llfuse_fuse_lookup(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_c_name) { struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_lookup", 0); /* "src/handlers.pxi":36 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":37 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * name = PyBytes_FromString(c_name) * with lock: */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 37, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":38 * try: * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) # <<<<<<<<<<<<<< * with lock: * entry = operations.lookup(parent, name, ctx) */ __pyx_t_4 = PyBytes_FromString(__pyx_v_c_name); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 38, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":39 * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) * with lock: # <<<<<<<<<<<<<< * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 39, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 39, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 39, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 39, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 39, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":40 * name = PyBytes_FromString(c_name) * with lock: * entry = operations.lookup(parent, name, ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_lookup); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(3+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_name); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 2+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 40, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 40, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":39 * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) * with lock: # <<<<<<<<<<<<<< * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_lookup", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_13) < 0) __PYX_ERR(1, 39, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 39, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 39, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 39, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_13); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 39, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__5, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 39, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":41 * with lock: * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 41, __pyx_L3_error) } __pyx_v_ret = fuse_reply_entry(__pyx_v_req, (&__pyx_v_entry->fuse_param)); /* "src/handlers.pxi":36 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":42 * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_lookup", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 42, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":43 * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 43, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 43, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":42 * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_12 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":44 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_lookup", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_13) < 0) __PYX_ERR(1, 44, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":45 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":36 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":47 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_lookup(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":48 * * if ret != 0: * log.error('fuse_lookup(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_lookup_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_lookup_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_lookup_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_lookup_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_lookup_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 48, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":47 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_lookup(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":31 * log.exception('Exception after kill:') * * cdef void fuse_lookup (fuse_req_t req, fuse_ino_t parent, # <<<<<<<<<<<<<< * const_char *c_name) with gil: * cdef EntryAttributes entry */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_lookup", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":51 * * * cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, # <<<<<<<<<<<<<< * ulong_t nlookup) with gil: * try: */ static void __pyx_f_6llfuse_fuse_forget(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, unsigned long __pyx_v_nlookup) { __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; int __pyx_t_15; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_forget", 0); /* "src/handlers.pxi":53 * cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, * ulong_t nlookup) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.forget([(ino, nlookup)]) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":54 * ulong_t nlookup) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.forget([(ino, nlookup)]) * except: */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 54, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 54, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 54, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 54, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 54, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":55 * try: * with lock: * operations.forget([(ino, nlookup)]) # <<<<<<<<<<<<<< * except: * handle_exc(NULL) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_forget); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_unsigned_long(__pyx_v_nlookup); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = PyTuple_New(2); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_12, 1, __pyx_t_8); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_8 = PyList_New(1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyList_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = 0; __pyx_t_12 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_12) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_8); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_12, __pyx_t_8}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_12, __pyx_t_8}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_12); __pyx_t_12 = NULL; __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_t_8); __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 55, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":54 * ulong_t nlookup) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.forget([(ino, nlookup)]) * except: */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_forget", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(1, 54, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 54, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 54, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (__pyx_t_14 < 0) __PYX_ERR(1, 54, __pyx_L19_except_error) __pyx_t_15 = ((!(__pyx_t_14 != 0)) != 0); if (__pyx_t_15) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_7); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_7 = 0; __PYX_ERR(1, 54, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__6, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 54, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":53 * cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, * ulong_t nlookup) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.forget([(ino, nlookup)]) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":56 * with lock: * operations.forget([(ino, nlookup)]) * except: # <<<<<<<<<<<<<< * handle_exc(NULL) * fuse_reply_none(req) */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_forget", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 56, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); /* "src/handlers.pxi":57 * operations.forget([(ino, nlookup)]) * except: * handle_exc(NULL) # <<<<<<<<<<<<<< * fuse_reply_none(req) * */ __pyx_f_6llfuse_handle_exc(NULL); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":53 * cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, * ulong_t nlookup) with gil: * try: # <<<<<<<<<<<<<< * with lock: * operations.forget([(ino, nlookup)]) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":58 * except: * handle_exc(NULL) * fuse_reply_none(req) # <<<<<<<<<<<<<< * * */ fuse_reply_none(__pyx_v_req); /* "src/handlers.pxi":51 * * * cdef void fuse_forget (fuse_req_t req, fuse_ino_t ino, # <<<<<<<<<<<<<< * ulong_t nlookup) with gil: * try: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_WriteUnraisable("llfuse.fuse_forget", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":61 * * * cdef void fuse_forget_multi(fuse_req_t req, size_t count, # <<<<<<<<<<<<<< * fuse_forget_data *forgets) with gil: * try: */ static void __pyx_f_6llfuse_fuse_forget_multi(fuse_req_t __pyx_v_req, size_t __pyx_v_count, struct fuse_forget_data *__pyx_v_forgets) { PyObject *__pyx_v_forget_list = NULL; size_t __pyx_v_i; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; size_t __pyx_t_5; size_t __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; int __pyx_t_9; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_forget_multi", 0); /* "src/handlers.pxi":63 * cdef void fuse_forget_multi(fuse_req_t req, size_t count, * fuse_forget_data *forgets) with gil: * try: # <<<<<<<<<<<<<< * forget_list = list() * for i in range(0, count): */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":64 * fuse_forget_data *forgets) with gil: * try: * forget_list = list() # <<<<<<<<<<<<<< * for i in range(0, count): * forget_list.append((forgets[i].ino, forgets[i].nlookup)) */ __pyx_t_4 = PyList_New(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 64, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_forget_list = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":65 * try: * forget_list = list() * for i in range(0, count): # <<<<<<<<<<<<<< * forget_list.append((forgets[i].ino, forgets[i].nlookup)) * with lock: */ __pyx_t_5 = __pyx_v_count; for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) { __pyx_v_i = __pyx_t_6; /* "src/handlers.pxi":66 * forget_list = list() * for i in range(0, count): * forget_list.append((forgets[i].ino, forgets[i].nlookup)) # <<<<<<<<<<<<<< * with lock: * operations.forget(forget_list) */ __pyx_t_4 = __Pyx_PyInt_From_uint64_t((__pyx_v_forgets[__pyx_v_i]).ino); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 66, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = __Pyx_PyInt_From_uint64_t((__pyx_v_forgets[__pyx_v_i]).nlookup); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 66, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 66, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_7); __pyx_t_4 = 0; __pyx_t_7 = 0; __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_forget_list, __pyx_t_8); if (unlikely(__pyx_t_9 == -1)) __PYX_ERR(1, 66, __pyx_L3_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } /* "src/handlers.pxi":67 * for i in range(0, count): * forget_list.append((forgets[i].ino, forgets[i].nlookup)) * with lock: # <<<<<<<<<<<<<< * operations.forget(forget_list) * except: */ /*with:*/ { __pyx_t_8 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 67, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_10 = __Pyx_PyObject_LookupSpecial(__pyx_t_8, __pyx_n_s_exit); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 67, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_8, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 67, __pyx_L13_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_11 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_11)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_11); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_11) { __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 67, __pyx_L13_error) __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } else { __pyx_t_7 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 67, __pyx_L13_error) } __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_12, &__pyx_t_13, &__pyx_t_14); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_14); /*try:*/ { /* "src/handlers.pxi":68 * forget_list.append((forgets[i].ino, forgets[i].nlookup)) * with lock: * operations.forget(forget_list) # <<<<<<<<<<<<<< * except: * handle_exc(NULL) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_forget); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (!__pyx_t_4) { __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_v_forget_list); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_GOTREF(__pyx_t_8); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_v_forget_list}; __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_8); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[2] = {__pyx_t_4, __pyx_v_forget_list}; __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_8); } else #endif { __pyx_t_11 = PyTuple_New(1+1); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_4); __pyx_t_4 = NULL; __Pyx_INCREF(__pyx_v_forget_list); __Pyx_GIVEREF(__pyx_v_forget_list); PyTuple_SET_ITEM(__pyx_t_11, 0+1, __pyx_v_forget_list); __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_11, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 68, __pyx_L19_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; /* "src/handlers.pxi":67 * for i in range(0, count): * forget_list.append((forgets[i].ino, forgets[i].nlookup)) * with lock: # <<<<<<<<<<<<<< * operations.forget(forget_list) * except: */ } __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L26_try_end; __pyx_L19_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_forget_multi", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_7, &__pyx_t_11) < 0) __PYX_ERR(1, 67, __pyx_L21_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_11); __pyx_t_4 = PyTuple_Pack(3, __pyx_t_8, __pyx_t_7, __pyx_t_11); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 67, __pyx_L21_except_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_4, NULL); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 67, __pyx_L21_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 67, __pyx_L21_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ErrRestoreWithState(__pyx_t_8, __pyx_t_7, __pyx_t_11); __pyx_t_8 = 0; __pyx_t_7 = 0; __pyx_t_11 = 0; __PYX_ERR(1, 67, __pyx_L21_except_error) } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L20_exception_handled; } __pyx_L21_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ExceptionReset(__pyx_t_12, __pyx_t_13, __pyx_t_14); goto __pyx_L3_error; __pyx_L20_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ExceptionReset(__pyx_t_12, __pyx_t_13, __pyx_t_14); __pyx_L26_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_10) { __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_tuple__7, NULL); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 67, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } goto __pyx_L18; } __pyx_L18:; } goto __pyx_L30; __pyx_L13_error:; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; goto __pyx_L3_error; __pyx_L30:; } /* "src/handlers.pxi":63 * cdef void fuse_forget_multi(fuse_req_t req, size_t count, * fuse_forget_data *forgets) with gil: * try: # <<<<<<<<<<<<<< * forget_list = list() * for i in range(0, count): */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; /* "src/handlers.pxi":69 * with lock: * operations.forget(forget_list) * except: # <<<<<<<<<<<<<< * handle_exc(NULL) * fuse_reply_none(req) */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_forget_multi", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_11, &__pyx_t_7, &__pyx_t_8) < 0) __PYX_ERR(1, 69, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":70 * operations.forget(forget_list) * except: * handle_exc(NULL) # <<<<<<<<<<<<<< * fuse_reply_none(req) * */ __pyx_f_6llfuse_handle_exc(NULL); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":63 * cdef void fuse_forget_multi(fuse_req_t req, size_t count, * fuse_forget_data *forgets) with gil: * try: # <<<<<<<<<<<<<< * forget_list = list() * for i in range(0, count): */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":71 * except: * handle_exc(NULL) * fuse_reply_none(req) # <<<<<<<<<<<<<< * * cdef void fuse_getattr (fuse_req_t req, fuse_ino_t ino, */ fuse_reply_none(__pyx_v_req); /* "src/handlers.pxi":61 * * * cdef void fuse_forget_multi(fuse_req_t req, size_t count, # <<<<<<<<<<<<<< * fuse_forget_data *forgets) with gil: * try: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_11); __Pyx_WriteUnraisable("llfuse.fuse_forget_multi", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_forget_list); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":73 * fuse_reply_none(req) * * cdef void fuse_getattr (fuse_req_t req, fuse_ino_t ino, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_getattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, CYTHON_UNUSED struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_getattr", 0); /* "src/handlers.pxi":78 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":79 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * entry = operations.getattr(ino, ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 79, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":80 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.getattr(ino, ctx) * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 80, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 80, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 80, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 80, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 80, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":81 * ctx = get_request_context(req) * with lock: * entry = operations.getattr(ino, ctx) # <<<<<<<<<<<<<< * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_getattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 81, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 81, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":80 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.getattr(ino, ctx) * */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_getattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_13) < 0) __PYX_ERR(1, 80, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 80, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 80, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 80, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_13); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 80, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 80, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":83 * entry = operations.getattr(ino, ctx) * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 83, __pyx_L3_error) } if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 83, __pyx_L3_error) } __pyx_v_ret = fuse_reply_attr(__pyx_v_req, __pyx_v_entry->attr, __pyx_v_entry->fuse_param.attr_timeout); /* "src/handlers.pxi":78 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":84 * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_getattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 84, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":85 * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 85, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 85, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":84 * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_12 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":86 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_getattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_13) < 0) __PYX_ERR(1, 86, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":87 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":78 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":89 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":90 * * if ret != 0: * log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_setattr (fuse_req_t req, fuse_ino_t ino, struct_stat *stat, */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_getattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_getattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_getattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_getattr_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_getattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 90, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":89 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":73 * fuse_reply_none(req) * * cdef void fuse_getattr (fuse_req_t req, fuse_ino_t ino, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_getattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":92 * log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_setattr (fuse_req_t req, fuse_ino_t ino, struct_stat *stat, # <<<<<<<<<<<<<< * int to_set, fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_setattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, struct stat *__pyx_v_stat, int __pyx_v_to_set, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; struct timespec __pyx_v_now; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_fields = 0; struct stat *__pyx_v_attr; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_fh = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; struct stat *__pyx_t_5; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; int __pyx_t_10; PyObject *__pyx_t_11 = NULL; time_t __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; PyObject *__pyx_t_17 = NULL; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_setattr", 0); /* "src/handlers.pxi":100 * cdef struct_stat *attr * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * entry = EntryAttributes() */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":101 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * entry = EntryAttributes() * fields = SetattrFields.__new__(SetattrFields) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 101, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":102 * try: * ctx = get_request_context(req) * entry = EntryAttributes() # <<<<<<<<<<<<<< * fields = SetattrFields.__new__(SetattrFields) * string.memcpy(entry.attr, stat, sizeof(struct_stat)) */ __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_EntryAttributes), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 102, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":103 * ctx = get_request_context(req) * entry = EntryAttributes() * fields = SetattrFields.__new__(SetattrFields) # <<<<<<<<<<<<<< * string.memcpy(entry.attr, stat, sizeof(struct_stat)) * */ __pyx_t_4 = __pyx_tp_new_6llfuse_SetattrFields(((PyTypeObject *)__pyx_ptype_6llfuse_SetattrFields), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 103, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_SetattrFields)))) __PYX_ERR(1, 103, __pyx_L3_error) __pyx_v_fields = ((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":104 * entry = EntryAttributes() * fields = SetattrFields.__new__(SetattrFields) * string.memcpy(entry.attr, stat, sizeof(struct_stat)) # <<<<<<<<<<<<<< * * attr = entry.attr */ memcpy(__pyx_v_entry->attr, __pyx_v_stat, (sizeof(struct stat))); /* "src/handlers.pxi":106 * string.memcpy(entry.attr, stat, sizeof(struct_stat)) * * attr = entry.attr # <<<<<<<<<<<<<< * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): * ret = gettime_realtime(&now) */ __pyx_t_5 = __pyx_v_entry->attr; __pyx_v_attr = __pyx_t_5; /* "src/handlers.pxi":107 * * attr = entry.attr * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): # <<<<<<<<<<<<<< * ret = gettime_realtime(&now) * if ret != 0: */ __pyx_t_6 = ((__pyx_v_to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW)) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":108 * attr = entry.attr * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): * ret = gettime_realtime(&now) # <<<<<<<<<<<<<< * if ret != 0: * log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', */ __pyx_v_ret = gettime_realtime((&__pyx_v_now)); /* "src/handlers.pxi":109 * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): * ret = gettime_realtime(&now) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', * strerror(errno.errno)) */ __pyx_t_6 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":110 * ret = gettime_realtime(&now) * if ret != 0: * log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', # <<<<<<<<<<<<<< * strerror(errno.errno)) * */ __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_error); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":111 * if ret != 0: * log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', * strerror(errno.errno)) # <<<<<<<<<<<<<< * * if to_set & FUSE_SET_ATTR_ATIME: */ __pyx_t_7 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 111, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; __pyx_t_10 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_8))) { __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); if (likely(__pyx_t_9)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_8, function); __pyx_t_10 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_fuse_setattr_clock_gettime_CLOCK, __pyx_t_7}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_fuse_setattr_clock_gettime_CLOCK, __pyx_t_7}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_9); __pyx_t_9 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_setattr_clock_gettime_CLOCK); __Pyx_GIVEREF(__pyx_kp_u_fuse_setattr_clock_gettime_CLOCK); PyTuple_SET_ITEM(__pyx_t_11, 0+__pyx_t_10, __pyx_kp_u_fuse_setattr_clock_gettime_CLOCK); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_11, 1+__pyx_t_10, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_11, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 110, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":109 * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): * ret = gettime_realtime(&now) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setattr(): clock_gettime(CLOCK_REALTIME) failed with %s', * strerror(errno.errno)) */ } /* "src/handlers.pxi":107 * * attr = entry.attr * if to_set & (FUSE_SET_ATTR_ATIME_NOW | FUSE_SET_ATTR_MTIME_NOW): # <<<<<<<<<<<<<< * ret = gettime_realtime(&now) * if ret != 0: */ } /* "src/handlers.pxi":113 * strerror(errno.errno)) * * if to_set & FUSE_SET_ATTR_ATIME: # <<<<<<<<<<<<<< * fields.update_atime = True * elif to_set & FUSE_SET_ATTR_ATIME_NOW: */ __pyx_t_6 = ((__pyx_v_to_set & FUSE_SET_ATTR_ATIME) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":114 * * if to_set & FUSE_SET_ATTR_ATIME: * fields.update_atime = True # <<<<<<<<<<<<<< * elif to_set & FUSE_SET_ATTR_ATIME_NOW: * fields.update_atime = True */ __Pyx_INCREF(Py_True); __Pyx_GIVEREF(Py_True); __Pyx_GOTREF(__pyx_v_fields->update_atime); __Pyx_DECREF(__pyx_v_fields->update_atime); __pyx_v_fields->update_atime = Py_True; /* "src/handlers.pxi":113 * strerror(errno.errno)) * * if to_set & FUSE_SET_ATTR_ATIME: # <<<<<<<<<<<<<< * fields.update_atime = True * elif to_set & FUSE_SET_ATTR_ATIME_NOW: */ goto __pyx_L13; } /* "src/handlers.pxi":115 * if to_set & FUSE_SET_ATTR_ATIME: * fields.update_atime = True * elif to_set & FUSE_SET_ATTR_ATIME_NOW: # <<<<<<<<<<<<<< * fields.update_atime = True * attr.st_atime = now.tv_sec */ __pyx_t_6 = ((__pyx_v_to_set & FUSE_SET_ATTR_ATIME_NOW) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":116 * fields.update_atime = True * elif to_set & FUSE_SET_ATTR_ATIME_NOW: * fields.update_atime = True # <<<<<<<<<<<<<< * attr.st_atime = now.tv_sec * SET_ATIME_NS(attr, now.tv_nsec) */ __Pyx_INCREF(Py_True); __Pyx_GIVEREF(Py_True); __Pyx_GOTREF(__pyx_v_fields->update_atime); __Pyx_DECREF(__pyx_v_fields->update_atime); __pyx_v_fields->update_atime = Py_True; /* "src/handlers.pxi":117 * elif to_set & FUSE_SET_ATTR_ATIME_NOW: * fields.update_atime = True * attr.st_atime = now.tv_sec # <<<<<<<<<<<<<< * SET_ATIME_NS(attr, now.tv_nsec) * */ __pyx_t_12 = __pyx_v_now.tv_sec; __pyx_v_attr->st_atime = __pyx_t_12; /* "src/handlers.pxi":118 * fields.update_atime = True * attr.st_atime = now.tv_sec * SET_ATIME_NS(attr, now.tv_nsec) # <<<<<<<<<<<<<< * * if to_set & FUSE_SET_ATTR_MTIME: */ SET_ATIME_NS(__pyx_v_attr, __pyx_v_now.tv_nsec); /* "src/handlers.pxi":115 * if to_set & FUSE_SET_ATTR_ATIME: * fields.update_atime = True * elif to_set & FUSE_SET_ATTR_ATIME_NOW: # <<<<<<<<<<<<<< * fields.update_atime = True * attr.st_atime = now.tv_sec */ } __pyx_L13:; /* "src/handlers.pxi":120 * SET_ATIME_NS(attr, now.tv_nsec) * * if to_set & FUSE_SET_ATTR_MTIME: # <<<<<<<<<<<<<< * fields.update_mtime = True * elif to_set & FUSE_SET_ATTR_MTIME_NOW: */ __pyx_t_6 = ((__pyx_v_to_set & FUSE_SET_ATTR_MTIME) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":121 * * if to_set & FUSE_SET_ATTR_MTIME: * fields.update_mtime = True # <<<<<<<<<<<<<< * elif to_set & FUSE_SET_ATTR_MTIME_NOW: * fields.update_mtime = True */ __Pyx_INCREF(Py_True); __Pyx_GIVEREF(Py_True); __Pyx_GOTREF(__pyx_v_fields->update_mtime); __Pyx_DECREF(__pyx_v_fields->update_mtime); __pyx_v_fields->update_mtime = Py_True; /* "src/handlers.pxi":120 * SET_ATIME_NS(attr, now.tv_nsec) * * if to_set & FUSE_SET_ATTR_MTIME: # <<<<<<<<<<<<<< * fields.update_mtime = True * elif to_set & FUSE_SET_ATTR_MTIME_NOW: */ goto __pyx_L14; } /* "src/handlers.pxi":122 * if to_set & FUSE_SET_ATTR_MTIME: * fields.update_mtime = True * elif to_set & FUSE_SET_ATTR_MTIME_NOW: # <<<<<<<<<<<<<< * fields.update_mtime = True * attr.st_mtime = now.tv_sec */ __pyx_t_6 = ((__pyx_v_to_set & FUSE_SET_ATTR_MTIME_NOW) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":123 * fields.update_mtime = True * elif to_set & FUSE_SET_ATTR_MTIME_NOW: * fields.update_mtime = True # <<<<<<<<<<<<<< * attr.st_mtime = now.tv_sec * SET_MTIME_NS(attr, now.tv_nsec) */ __Pyx_INCREF(Py_True); __Pyx_GIVEREF(Py_True); __Pyx_GOTREF(__pyx_v_fields->update_mtime); __Pyx_DECREF(__pyx_v_fields->update_mtime); __pyx_v_fields->update_mtime = Py_True; /* "src/handlers.pxi":124 * elif to_set & FUSE_SET_ATTR_MTIME_NOW: * fields.update_mtime = True * attr.st_mtime = now.tv_sec # <<<<<<<<<<<<<< * SET_MTIME_NS(attr, now.tv_nsec) * */ __pyx_t_12 = __pyx_v_now.tv_sec; __pyx_v_attr->st_mtime = __pyx_t_12; /* "src/handlers.pxi":125 * fields.update_mtime = True * attr.st_mtime = now.tv_sec * SET_MTIME_NS(attr, now.tv_nsec) # <<<<<<<<<<<<<< * * fields.update_mode = bool(to_set & FUSE_SET_ATTR_MODE) */ SET_MTIME_NS(__pyx_v_attr, __pyx_v_now.tv_nsec); /* "src/handlers.pxi":122 * if to_set & FUSE_SET_ATTR_MTIME: * fields.update_mtime = True * elif to_set & FUSE_SET_ATTR_MTIME_NOW: # <<<<<<<<<<<<<< * fields.update_mtime = True * attr.st_mtime = now.tv_sec */ } __pyx_L14:; /* "src/handlers.pxi":127 * SET_MTIME_NS(attr, now.tv_nsec) * * fields.update_mode = bool(to_set & FUSE_SET_ATTR_MODE) # <<<<<<<<<<<<<< * fields.update_uid = bool(to_set & FUSE_SET_ATTR_UID) * fields.update_gid = bool(to_set & FUSE_SET_ATTR_GID) */ __pyx_t_4 = __Pyx_PyInt_From_int((__pyx_v_to_set & FUSE_SET_ATTR_MODE)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 127, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 127, __pyx_L3_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_6))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 127, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __Pyx_GOTREF(__pyx_v_fields->update_mode); __Pyx_DECREF(__pyx_v_fields->update_mode); __pyx_v_fields->update_mode = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":128 * * fields.update_mode = bool(to_set & FUSE_SET_ATTR_MODE) * fields.update_uid = bool(to_set & FUSE_SET_ATTR_UID) # <<<<<<<<<<<<<< * fields.update_gid = bool(to_set & FUSE_SET_ATTR_GID) * fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) */ __pyx_t_4 = __Pyx_PyInt_From_int((__pyx_v_to_set & FUSE_SET_ATTR_UID)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 128, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 128, __pyx_L3_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_6))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 128, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __Pyx_GOTREF(__pyx_v_fields->update_uid); __Pyx_DECREF(__pyx_v_fields->update_uid); __pyx_v_fields->update_uid = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":129 * fields.update_mode = bool(to_set & FUSE_SET_ATTR_MODE) * fields.update_uid = bool(to_set & FUSE_SET_ATTR_UID) * fields.update_gid = bool(to_set & FUSE_SET_ATTR_GID) # <<<<<<<<<<<<<< * fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) * */ __pyx_t_4 = __Pyx_PyInt_From_int((__pyx_v_to_set & FUSE_SET_ATTR_GID)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 129, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 129, __pyx_L3_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_6))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 129, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __Pyx_GOTREF(__pyx_v_fields->update_gid); __Pyx_DECREF(__pyx_v_fields->update_gid); __pyx_v_fields->update_gid = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":130 * fields.update_uid = bool(to_set & FUSE_SET_ATTR_UID) * fields.update_gid = bool(to_set & FUSE_SET_ATTR_GID) * fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) # <<<<<<<<<<<<<< * * if fi is NULL: */ __pyx_t_4 = __Pyx_PyInt_From_int((__pyx_v_to_set & FUSE_SET_ATTR_SIZE)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 130, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 130, __pyx_L3_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyBool_FromLong((!(!__pyx_t_6))); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 130, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_4); __Pyx_GOTREF(__pyx_v_fields->update_size); __Pyx_DECREF(__pyx_v_fields->update_size); __pyx_v_fields->update_size = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":132 * fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) * * if fi is NULL: # <<<<<<<<<<<<<< * fh = None * else: */ __pyx_t_6 = ((__pyx_v_fi == NULL) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":133 * * if fi is NULL: * fh = None # <<<<<<<<<<<<<< * else: * fh = fi.fh */ __Pyx_INCREF(Py_None); __pyx_v_fh = Py_None; /* "src/handlers.pxi":132 * fields.update_size = bool(to_set & FUSE_SET_ATTR_SIZE) * * if fi is NULL: # <<<<<<<<<<<<<< * fh = None * else: */ goto __pyx_L15; } /* "src/handlers.pxi":135 * fh = None * else: * fh = fi.fh # <<<<<<<<<<<<<< * with lock: * entry = operations.setattr(ino, entry, fields, fh, ctx) */ /*else*/ { __pyx_t_4 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 135, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_fh = __pyx_t_4; __pyx_t_4 = 0; } __pyx_L15:; /* "src/handlers.pxi":136 * else: * fh = fi.fh * with lock: # <<<<<<<<<<<<<< * entry = operations.setattr(ino, entry, fields, fh, ctx) * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 136, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_13 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 136, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_11 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 136, __pyx_L16_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_11))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_11); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_11); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_11, function); } } if (__pyx_t_7) { __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_t_11, __pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 136, __pyx_L16_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_8 = __Pyx_PyObject_CallNoArg(__pyx_t_11); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 136, __pyx_L16_error) } __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_14, &__pyx_t_15, &__pyx_t_16); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_16); /*try:*/ { /* "src/handlers.pxi":137 * fh = fi.fh * with lock: * entry = operations.setattr(ino, entry, fields, fh, ctx) # <<<<<<<<<<<<<< * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_setattr); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_11 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_7 = NULL; __pyx_t_10 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_8); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_8, function); __pyx_t_10 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[6] = {__pyx_t_7, __pyx_t_11, ((PyObject *)__pyx_v_entry), ((PyObject *)__pyx_v_fields), __pyx_v_fh, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_10, 5+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[6] = {__pyx_t_7, __pyx_t_11, ((PyObject *)__pyx_v_entry), ((PyObject *)__pyx_v_fields), __pyx_v_fh, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_10, 5+__pyx_t_10); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } else #endif { __pyx_t_9 = PyTuple_New(5+__pyx_t_10); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_10, __pyx_t_11); __Pyx_INCREF(((PyObject *)__pyx_v_entry)); __Pyx_GIVEREF(((PyObject *)__pyx_v_entry)); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_10, ((PyObject *)__pyx_v_entry)); __Pyx_INCREF(((PyObject *)__pyx_v_fields)); __Pyx_GIVEREF(((PyObject *)__pyx_v_fields)); PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_10, ((PyObject *)__pyx_v_fields)); __Pyx_INCREF(__pyx_v_fh); __Pyx_GIVEREF(__pyx_v_fh); PyTuple_SET_ITEM(__pyx_t_9, 3+__pyx_t_10, __pyx_v_fh); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_9, 4+__pyx_t_10, __pyx_v_ctx); __pyx_t_11 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_9, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 137, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 137, __pyx_L22_error) __pyx_t_8 = __pyx_t_4; __Pyx_INCREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF_SET(__pyx_v_entry, ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_8)); __pyx_t_8 = 0; /* "src/handlers.pxi":136 * else: * fh = fi.fh * with lock: # <<<<<<<<<<<<<< * entry = operations.setattr(ino, entry, fields, fh, ctx) * */ } __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0; goto __pyx_L29_try_end; __pyx_L22_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_setattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_4, &__pyx_t_9) < 0) __PYX_ERR(1, 136, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_9); __pyx_t_11 = PyTuple_Pack(3, __pyx_t_8, __pyx_t_4, __pyx_t_9); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 136, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_13, __pyx_t_11, NULL); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 136, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_17); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_17); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; if (__pyx_t_6 < 0) __PYX_ERR(1, 136, __pyx_L24_except_error) __pyx_t_18 = ((!(__pyx_t_6 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_9); __Pyx_ErrRestoreWithState(__pyx_t_8, __pyx_t_4, __pyx_t_9); __pyx_t_8 = 0; __pyx_t_4 = 0; __pyx_t_9 = 0; __PYX_ERR(1, 136, __pyx_L24_except_error) } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; goto __pyx_L23_exception_handled; } __pyx_L24_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_ExceptionReset(__pyx_t_14, __pyx_t_15, __pyx_t_16); goto __pyx_L3_error; __pyx_L23_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_ExceptionReset(__pyx_t_14, __pyx_t_15, __pyx_t_16); __pyx_L29_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_13) { __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_13, __pyx_tuple__9, NULL); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 136, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; } goto __pyx_L21; } __pyx_L21:; } goto __pyx_L33; __pyx_L16_error:; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L3_error; __pyx_L33:; } /* "src/handlers.pxi":139 * entry = operations.setattr(ino, entry, fields, fh, ctx) * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_attr(__pyx_v_req, __pyx_v_entry->attr, __pyx_v_entry->fuse_param.attr_timeout); /* "src/handlers.pxi":100 * cdef struct_stat *attr * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * entry = EntryAttributes() */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; /* "src/handlers.pxi":140 * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_10 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_10) { __Pyx_AddTraceback("llfuse.fuse_setattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_9, &__pyx_t_4, &__pyx_t_8) < 0) __PYX_ERR(1, 140, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_8); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":141 * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 141, __pyx_L39_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_10 = __Pyx_PyInt_As_int(__pyx_t_11); if (unlikely((__pyx_t_10 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 141, __pyx_L39_error) __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_10); } /* "src/handlers.pxi":140 * * ret = fuse_reply_attr(req, entry.attr, entry.fuse_param.attr_timeout) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L40; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L39_error:; __pyx_t_13 = 0; __pyx_t_16 = 0; __pyx_t_15 = 0; __pyx_t_14 = 0; __pyx_t_17 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_14, &__pyx_t_17, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_13, &__pyx_t_16, &__pyx_t_15) < 0)) __Pyx_ErrFetch(&__pyx_t_13, &__pyx_t_16, &__pyx_t_15); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_10 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_14, __pyx_t_17, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestore(__pyx_t_13, __pyx_t_16, __pyx_t_15); __pyx_t_13 = 0; __pyx_t_16 = 0; __pyx_t_15 = 0; __pyx_t_14 = 0; __pyx_t_17 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_10; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L40:; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":142 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_setattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_4, &__pyx_t_9) < 0) __PYX_ERR(1, 142, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_9); /* "src/handlers.pxi":143 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":100 * cdef struct_stat *attr * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * entry = EntryAttributes() */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":145 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":146 * * if ret != 0: * log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_readlink (fuse_req_t req, fuse_ino_t ino) with gil: */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_11 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_8))) { __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_8); if (likely(__pyx_t_11)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); __Pyx_INCREF(__pyx_t_11); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_8, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[3] = {__pyx_t_11, __pyx_kp_u_fuse_setattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_9 = __Pyx_PyFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_8)) { PyObject *__pyx_temp[3] = {__pyx_t_11, __pyx_kp_u_fuse_setattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_9 = __Pyx_PyCFunction_FastCall(__pyx_t_8, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_11) { __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_11); __pyx_t_11 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_setattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_setattr_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_19, __pyx_kp_u_fuse_setattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_19, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_9 = __Pyx_PyObject_Call(__pyx_t_8, __pyx_t_7, NULL); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; /* "src/handlers.pxi":145 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":92 * log.error('fuse_getattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_setattr (fuse_req_t req, fuse_ino_t ino, struct_stat *stat, # <<<<<<<<<<<<<< * int to_set, fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __Pyx_XDECREF(__pyx_t_11); __Pyx_WriteUnraisable("llfuse.fuse_setattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF((PyObject *)__pyx_v_fields); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_fh); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":148 * log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_readlink (fuse_req_t req, fuse_ino_t ino) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef char* name */ static void __pyx_f_6llfuse_fuse_readlink(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino) { int __pyx_v_ret; char *__pyx_v_name; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_target = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; char *__pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_readlink", 0); /* "src/handlers.pxi":151 * cdef int ret * cdef char* name * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":152 * cdef char* name * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * target = operations.readlink(ino, ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 152, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":153 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * target = operations.readlink(ino, ctx) * name = PyBytes_AsString(target) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 153, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 153, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 153, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 153, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 153, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":154 * ctx = get_request_context(req) * with lock: * target = operations.readlink(ino, ctx) # <<<<<<<<<<<<<< * name = PyBytes_AsString(target) * ret = fuse_reply_readlink(req, name) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_readlink); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 154, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_target = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":153 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * target = operations.readlink(ino, ctx) * name = PyBytes_AsString(target) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_readlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 153, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 153, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 153, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 153, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_13); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 153, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__10, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 153, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":155 * with lock: * target = operations.readlink(ino, ctx) * name = PyBytes_AsString(target) # <<<<<<<<<<<<<< * ret = fuse_reply_readlink(req, name) * except FUSEError as e: */ if (unlikely(!__pyx_v_target)) { __Pyx_RaiseUnboundLocalError("target"); __PYX_ERR(1, 155, __pyx_L3_error) } __pyx_t_17 = PyBytes_AsString(__pyx_v_target); if (unlikely(__pyx_t_17 == NULL)) __PYX_ERR(1, 155, __pyx_L3_error) __pyx_v_name = __pyx_t_17; /* "src/handlers.pxi":156 * target = operations.readlink(ino, ctx) * name = PyBytes_AsString(target) * ret = fuse_reply_readlink(req, name) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_readlink(__pyx_v_req, __pyx_v_name); /* "src/handlers.pxi":151 * cdef int ret * cdef char* name * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":157 * name = PyBytes_AsString(target) * ret = fuse_reply_readlink(req, name) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_readlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 157, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":158 * ret = fuse_reply_readlink(req, name) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 158, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 158, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":157 * name = PyBytes_AsString(target) * ret = fuse_reply_readlink(req, name) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_12 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":159 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_readlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 159, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":160 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":151 * cdef int ret * cdef char* name * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":162 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":163 * * if ret != 0: * log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_mknod (fuse_req_t req, fuse_ino_t parent, const_char *name, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_readlink_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_readlink_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_readlink_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_readlink_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_18, __pyx_kp_u_fuse_readlink_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":162 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":148 * log.error('fuse_setattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_readlink (fuse_req_t req, fuse_ino_t ino) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef char* name */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_readlink", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_target); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":165 * log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_mknod (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * mode_t mode, dev_t rdev) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_mknod(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name, mode_t __pyx_v_mode, dev_t __pyx_v_rdev) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; PyObject *__pyx_t_16 = NULL; PyObject *__pyx_t_17 = NULL; int __pyx_t_18; int __pyx_t_19; int __pyx_t_20; char const *__pyx_t_21; PyObject *__pyx_t_22 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_mknod", 0); /* "src/handlers.pxi":170 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":171 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * entry = operations.mknod(parent, PyBytes_FromString(name), */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 171, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":172 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mknod(parent, PyBytes_FromString(name), * mode, rdev, ctx) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 172, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 172, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 172, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 172, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 172, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":173 * ctx = get_request_context(req) * with lock: * entry = operations.mknod(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * mode, rdev, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_mknod); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":174 * with lock: * entry = operations.mknod(parent, PyBytes_FromString(name), * mode, rdev, ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: */ __pyx_t_12 = __Pyx_PyInt_From_mode_t(__pyx_v_mode); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 174, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = __Pyx_PyInt_From_dev_t(__pyx_v_rdev); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 174, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = NULL; __pyx_t_15 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_14 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_14)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_14); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_15 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_14, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_t_13, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_15, 5+__pyx_t_15); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_14, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_t_13, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_15, 5+__pyx_t_15); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } else #endif { __pyx_t_16 = PyTuple_New(5+__pyx_t_15); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_16); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_14); PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_14); __pyx_t_14 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_16, 0+__pyx_t_15, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_16, 1+__pyx_t_15, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_16, 2+__pyx_t_15, __pyx_t_12); __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_16, 3+__pyx_t_15, __pyx_t_13); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_16, 4+__pyx_t_15, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_16, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 173, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":173 * ctx = get_request_context(req) * with lock: * entry = operations.mknod(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * mode, rdev, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 173, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":172 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mknod(parent, PyBytes_FromString(name), * mode, rdev, ctx) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_mknod", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_16) < 0) __PYX_ERR(1, 172, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_16); __pyx_t_13 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_16); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 172, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_13, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 172, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_17); __pyx_t_18 = __Pyx_PyObject_IsTrue(__pyx_t_17); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; if (__pyx_t_18 < 0) __PYX_ERR(1, 172, __pyx_L19_except_error) __pyx_t_19 = ((!(__pyx_t_18 != 0)) != 0); if (__pyx_t_19) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_16); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_16 = 0; __PYX_ERR(1, 172, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__11, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 172, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":175 * entry = operations.mknod(parent, PyBytes_FromString(name), * mode, rdev, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 175, __pyx_L3_error) } __pyx_v_ret = fuse_reply_entry(__pyx_v_req, (&__pyx_v_entry->fuse_param)); /* "src/handlers.pxi":170 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0; /* "src/handlers.pxi":176 * mode, rdev, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_15 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_15) { __Pyx_AddTraceback("llfuse.fuse_mknod", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_16, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 176, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":177 * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 177, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_15 = __Pyx_PyInt_As_int(__pyx_t_13); if (unlikely((__pyx_t_15 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 177, __pyx_L34_error) __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_15); } /* "src/handlers.pxi":176 * mode, rdev, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_17, &__pyx_t_22); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_22); __pyx_t_15 = __pyx_lineno; __pyx_t_20 = __pyx_clineno; __pyx_t_21 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_22); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_17, __pyx_t_22); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __pyx_lineno = __pyx_t_15; __pyx_clineno = __pyx_t_20; __pyx_filename = __pyx_t_21; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":178 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_mknod", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_16) < 0) __PYX_ERR(1, 178, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_16); /* "src/handlers.pxi":179 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":170 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":181 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_19 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_19) { /* "src/handlers.pxi":182 * * if ret != 0: * log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_mkdir (fuse_req_t req, fuse_ino_t parent, const_char *name, */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_13 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_kp_u_fuse_mknod_fuse_reply__failed_wi, __pyx_t_4}; __pyx_t_16 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_kp_u_fuse_mknod_fuse_reply__failed_wi, __pyx_t_4}; __pyx_t_16 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_12 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_mknod_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_mknod_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_12, 0+__pyx_t_20, __pyx_kp_u_fuse_mknod_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_12, 1+__pyx_t_20, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_12, NULL); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 182, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; /* "src/handlers.pxi":181 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":165 * log.error('fuse_readlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_mknod (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * mode_t mode, dev_t rdev) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_14); __Pyx_XDECREF(__pyx_t_16); __Pyx_WriteUnraisable("llfuse.fuse_mknod", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":184 * log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_mkdir (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * mode_t mode) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_mkdir(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name, mode_t __pyx_v_mode) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_mkdir", 0); /* "src/handlers.pxi":189 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * # Force the entry type to directory. We need to explicitly cast, * # because on BSD the S_* are not of type mode_t. */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":192 * # Force the entry type to directory. We need to explicitly cast, * # because on BSD the S_* are not of type mode_t. * mode = (mode & ~ S_IFMT) | S_IFDIR # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __pyx_v_mode = ((__pyx_v_mode & (~((mode_t)S_IFMT))) | ((mode_t)S_IFDIR)); /* "src/handlers.pxi":193 * # because on BSD the S_* are not of type mode_t. * mode = (mode & ~ S_IFMT) | S_IFDIR * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * entry = operations.mkdir(parent, PyBytes_FromString(name), */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 193, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":194 * mode = (mode & ~ S_IFMT) | S_IFDIR * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mkdir(parent, PyBytes_FromString(name), * mode, ctx) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 194, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 194, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 194, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 194, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 194, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":195 * ctx = get_request_context(req) * with lock: * entry = operations.mkdir(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * mode, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_mkdir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":196 * with lock: * entry = operations.mkdir(parent, PyBytes_FromString(name), * mode, ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: */ __pyx_t_12 = __Pyx_PyInt_From_mode_t(__pyx_v_mode); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 196, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif { __pyx_t_15 = PyTuple_New(4+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_t_12); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_15, 3+__pyx_t_14, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 195, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":195 * ctx = get_request_context(req) * with lock: * entry = operations.mkdir(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * mode, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 195, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":194 * mode = (mode & ~ S_IFMT) | S_IFDIR * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mkdir(parent, PyBytes_FromString(name), * mode, ctx) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 194, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); __pyx_t_12 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 194, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 194, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 194, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_15); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 194, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 194, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":197 * entry = operations.mkdir(parent, PyBytes_FromString(name), * mode, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 197, __pyx_L3_error) } __pyx_v_ret = fuse_reply_entry(__pyx_v_req, (&__pyx_v_entry->fuse_param)); /* "src/handlers.pxi":189 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * # Force the entry type to directory. We need to explicitly cast, * # because on BSD the S_* are not of type mode_t. */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":198 * mode, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 198, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":199 * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 199, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_12); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 199, __pyx_L34_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":198 * mode, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_14 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":200 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 200, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":201 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":189 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * # Force the entry type to directory. We need to explicitly cast, * # because on BSD the S_* are not of type mode_t. */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":203 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":204 * * if ret != 0: * log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_unlink (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_12 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi, __pyx_t_4}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi, __pyx_t_4}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_19, __pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_19, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 204, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":203 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":184 * log.error('fuse_mknod(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_mkdir (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * mode_t mode) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_mkdir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":206 * log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_unlink (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_unlink(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_unlink", 0); /* "src/handlers.pxi":209 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":210 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * operations.unlink(parent, PyBytes_FromString(name), ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 210, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":211 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 211, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 211, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 211, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 211, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 211, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":212 * ctx = get_request_context(req) * with lock: * operations.unlink(parent, PyBytes_FromString(name), ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_unlink); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(3+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_14, 2+__pyx_t_13, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 212, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":211 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_unlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 211, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 211, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 211, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 211, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 211, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__13, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 211, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":213 * with lock: * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":209 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":214 * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_unlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 214, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":215 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 215, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 215, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":214 * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_13 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":216 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_unlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 216, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":217 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":209 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":219 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":220 * * if ret != 0: * log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_rmdir (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_unlink_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_unlink_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_unlink_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_unlink_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_18, __pyx_kp_u_fuse_unlink_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":219 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":206 * log.error('fuse_mkdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_unlink (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_unlink", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":222 * log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_rmdir (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_rmdir(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_rmdir", 0); /* "src/handlers.pxi":225 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":226 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * operations.rmdir(parent, PyBytes_FromString(name), ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 226, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":227 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 227, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 227, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 227, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 227, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 227, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":228 * ctx = get_request_context(req) * with lock: * operations.rmdir(parent, PyBytes_FromString(name), ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_rmdir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(3+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_14, 2+__pyx_t_13, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 228, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":227 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 227, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 227, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 227, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 227, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 227, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__14, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 227, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":229 * with lock: * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":225 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":230 * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 230, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":231 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 231, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 231, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":230 * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_13 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":232 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 232, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":233 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":225 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":235 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":236 * * if ret != 0: * log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_symlink (fuse_req_t req, const_char *link, fuse_ino_t parent, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_18, __pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 236, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":235 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":222 * log.error('fuse_unlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_rmdir (fuse_req_t req, fuse_ino_t parent, const_char *name) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_rmdir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":238 * log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_symlink (fuse_req_t req, const_char *link, fuse_ino_t parent, # <<<<<<<<<<<<<< * const_char *name) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_symlink(fuse_req_t __pyx_v_req, const char *__pyx_v_link, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_symlink", 0); /* "src/handlers.pxi":243 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":244 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * entry = operations.symlink(parent, PyBytes_FromString(name), */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 244, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":245 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.symlink(parent, PyBytes_FromString(name), * PyBytes_FromString(link), ctx) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 245, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 245, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 245, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 245, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 245, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":246 * ctx = get_request_context(req) * with lock: * entry = operations.symlink(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * PyBytes_FromString(link), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_symlink); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":247 * with lock: * entry = operations.symlink(parent, PyBytes_FromString(name), * PyBytes_FromString(link), ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: */ __pyx_t_12 = PyBytes_FromString(__pyx_v_link); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 247, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif { __pyx_t_15 = PyTuple_New(4+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_t_12); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_15, 3+__pyx_t_14, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 246, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":246 * ctx = get_request_context(req) * with lock: * entry = operations.symlink(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * PyBytes_FromString(link), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 246, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":245 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.symlink(parent, PyBytes_FromString(name), * PyBytes_FromString(link), ctx) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_symlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 245, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); __pyx_t_12 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 245, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 245, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 245, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_15); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 245, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__15, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 245, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":248 * entry = operations.symlink(parent, PyBytes_FromString(name), * PyBytes_FromString(link), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 248, __pyx_L3_error) } __pyx_v_ret = fuse_reply_entry(__pyx_v_req, (&__pyx_v_entry->fuse_param)); /* "src/handlers.pxi":243 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":249 * PyBytes_FromString(link), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_symlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 249, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":250 * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 250, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_12); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 250, __pyx_L34_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":249 * PyBytes_FromString(link), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_14 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":251 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_symlink", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 251, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":252 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":243 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":254 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":255 * * if ret != 0: * log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_rename (fuse_req_t req, fuse_ino_t parent, const_char *name, */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_12 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_symlink_fuse_reply__failed, __pyx_t_4}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_symlink_fuse_reply__failed, __pyx_t_4}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_symlink_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_symlink_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_19, __pyx_kp_u_fuse_symlink_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_19, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 255, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":254 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":238 * log.error('fuse_rmdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_symlink (fuse_req_t req, const_char *link, fuse_ino_t parent, # <<<<<<<<<<<<<< * const_char *name) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_symlink", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":257 * log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_rename (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * fuse_ino_t newparent, const_char *newname) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_rename(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_name, fuse_ino_t __pyx_v_newparent, const char *__pyx_v_newname) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; PyObject *__pyx_t_16 = NULL; PyObject *__pyx_t_17 = NULL; int __pyx_t_18; int __pyx_t_19; int __pyx_t_20; char const *__pyx_t_21; PyObject *__pyx_t_22 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_rename", 0); /* "src/handlers.pxi":261 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":262 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * operations.rename(parent, PyBytes_FromString(name), */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 262, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":263 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rename(parent, PyBytes_FromString(name), * newparent, PyBytes_FromString(newname), ctx) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 263, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 263, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 263, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 263, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 263, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":264 * ctx = get_request_context(req) * with lock: * operations.rename(parent, PyBytes_FromString(name), # <<<<<<<<<<<<<< * newparent, PyBytes_FromString(newname), ctx) * ret = fuse_reply_err(req, 0) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_rename); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyBytes_FromString(__pyx_v_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":265 * with lock: * operations.rename(parent, PyBytes_FromString(name), * newparent, PyBytes_FromString(newname), ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_12 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_newparent); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 265, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = PyBytes_FromString(__pyx_v_newname); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 265, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = NULL; __pyx_t_15 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_14 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_14)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_14); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_15 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_14, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_t_13, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_15, 5+__pyx_t_15); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_14, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_t_13, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_15, 5+__pyx_t_15); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } else #endif { __pyx_t_16 = PyTuple_New(5+__pyx_t_15); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_16); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_14); PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_14); __pyx_t_14 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_16, 0+__pyx_t_15, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_16, 1+__pyx_t_15, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_16, 2+__pyx_t_15, __pyx_t_12); __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_16, 3+__pyx_t_15, __pyx_t_13); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_16, 4+__pyx_t_15, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_16, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 264, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":263 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rename(parent, PyBytes_FromString(name), * newparent, PyBytes_FromString(newname), ctx) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_rename", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_16) < 0) __PYX_ERR(1, 263, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_16); __pyx_t_13 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_16); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 263, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_13, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 263, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_17); __pyx_t_18 = __Pyx_PyObject_IsTrue(__pyx_t_17); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; if (__pyx_t_18 < 0) __PYX_ERR(1, 263, __pyx_L19_except_error) __pyx_t_19 = ((!(__pyx_t_18 != 0)) != 0); if (__pyx_t_19) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_16); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_16 = 0; __PYX_ERR(1, 263, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__16, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 263, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":266 * operations.rename(parent, PyBytes_FromString(name), * newparent, PyBytes_FromString(newname), ctx) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":261 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_16); __pyx_t_16 = 0; /* "src/handlers.pxi":267 * newparent, PyBytes_FromString(newname), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_15 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_15) { __Pyx_AddTraceback("llfuse.fuse_rename", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_16, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 267, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":268 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 268, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_15 = __Pyx_PyInt_As_int(__pyx_t_13); if (unlikely((__pyx_t_15 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 268, __pyx_L34_error) __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_15); } /* "src/handlers.pxi":267 * newparent, PyBytes_FromString(newname), ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_17, &__pyx_t_22); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_22); __pyx_t_15 = __pyx_lineno; __pyx_t_20 = __pyx_clineno; __pyx_t_21 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_22); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_17, __pyx_t_22); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __pyx_lineno = __pyx_t_15; __pyx_clineno = __pyx_t_20; __pyx_filename = __pyx_t_21; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":269 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_rename", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_16) < 0) __PYX_ERR(1, 269, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_16); /* "src/handlers.pxi":270 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":261 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":272 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_19 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_19) { /* "src/handlers.pxi":273 * * if ret != 0: * log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_link (fuse_req_t req, fuse_ino_t ino, fuse_ino_t newparent, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_13 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_kp_u_fuse_rename_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_16 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_13, __pyx_kp_u_fuse_rename_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_16 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_12 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_rename_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_rename_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_12, 0+__pyx_t_20, __pyx_kp_u_fuse_rename_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_12, 1+__pyx_t_20, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_12, NULL); if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_16); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; /* "src/handlers.pxi":272 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":257 * log.error('fuse_symlink(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_rename (fuse_req_t req, fuse_ino_t parent, const_char *name, # <<<<<<<<<<<<<< * fuse_ino_t newparent, const_char *newname) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_14); __Pyx_XDECREF(__pyx_t_16); __Pyx_WriteUnraisable("llfuse.fuse_rename", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":275 * log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_link (fuse_req_t req, fuse_ino_t ino, fuse_ino_t newparent, # <<<<<<<<<<<<<< * const_char *newname) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_link(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, fuse_ino_t __pyx_v_newparent, const char *__pyx_v_newname) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_link", 0); /* "src/handlers.pxi":280 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":281 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * entry = operations.link(ino, newparent, */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 281, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":282 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.link(ino, newparent, * PyBytes_FromString(newname), ctx) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 282, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 282, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 282, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 282, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 282, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":283 * ctx = get_request_context(req) * with lock: * entry = operations.link(ino, newparent, # <<<<<<<<<<<<<< * PyBytes_FromString(newname), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_link); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_newparent); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":284 * with lock: * entry = operations.link(ino, newparent, * PyBytes_FromString(newname), ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: */ __pyx_t_12 = PyBytes_FromString(__pyx_v_newname); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 284, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[5] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif { __pyx_t_15 = PyTuple_New(4+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_t_12); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_15, 3+__pyx_t_14, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 283, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":283 * ctx = get_request_context(req) * with lock: * entry = operations.link(ino, newparent, # <<<<<<<<<<<<<< * PyBytes_FromString(newname), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 283, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":282 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.link(ino, newparent, * PyBytes_FromString(newname), ctx) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_link", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 282, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); __pyx_t_12 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 282, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 282, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 282, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_15); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 282, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__17, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 282, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":285 * entry = operations.link(ino, newparent, * PyBytes_FromString(newname), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 285, __pyx_L3_error) } __pyx_v_ret = fuse_reply_entry(__pyx_v_req, (&__pyx_v_entry->fuse_param)); /* "src/handlers.pxi":280 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":286 * PyBytes_FromString(newname), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_link", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 286, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":287 * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 287, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_12); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 287, __pyx_L34_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":286 * PyBytes_FromString(newname), ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_14 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":288 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_link", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 288, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":289 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":280 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":291 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":292 * * if ret != 0: * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_12 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_link_fuse_reply__failed_wit, __pyx_t_4}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_link_fuse_reply__failed_wit, __pyx_t_4}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_link_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_kp_u_fuse_link_fuse_reply__failed_wit); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_19, __pyx_kp_u_fuse_link_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_19, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 292, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":291 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":275 * log.error('fuse_rename(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_link (fuse_req_t req, fuse_ino_t ino, fuse_ino_t newparent, # <<<<<<<<<<<<<< * const_char *newname) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_link", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":295 * * * cdef void fuse_open (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_open(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; uint64_t __pyx_t_15; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_open", 0); /* "src/handlers.pxi":298 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":299 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * fi.fh = operations.open(ino, fi.flags, ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 299, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":300 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.open(ino, fi.flags, ctx) * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 300, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 300, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 300, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 300, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 300, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":301 * ctx = get_request_context(req) * with lock: * fi.fh = operations.open(ino, fi.flags, ctx) # <<<<<<<<<<<<<< * * # Cached file data does not need to be invalidated. */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_open); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_fi->flags); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(3+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_14, 2+__pyx_t_13, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_15 = __Pyx_PyInt_As_uint64_t(__pyx_t_4); if (unlikely((__pyx_t_15 == ((uint64_t)-1)) && PyErr_Occurred())) __PYX_ERR(1, 301, __pyx_L17_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_fi->fh = __pyx_t_15; /* "src/handlers.pxi":300 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.open(ino, fi.flags, ctx) * */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_open", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 300, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 300, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 300, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 300, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 300, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__18, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 300, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":305 * # Cached file data does not need to be invalidated. * # http://article.gmane.org/gmane.comp.file-systems.fuse.devel/5325/ * fi.keep_cache = 1 # <<<<<<<<<<<<<< * * ret = fuse_reply_open(req, fi) */ __pyx_v_fi->keep_cache = 1; /* "src/handlers.pxi":307 * fi.keep_cache = 1 * * ret = fuse_reply_open(req, fi) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_open(__pyx_v_req, __pyx_v_fi); /* "src/handlers.pxi":298 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":308 * * ret = fuse_reply_open(req, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_open", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 308, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":309 * ret = fuse_reply_open(req, fi) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 309, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 309, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":308 * * ret = fuse_reply_open(req, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_13 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":310 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_open", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 310, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":311 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":298 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":313 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":314 * * if ret != 0: * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_read (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_link_fuse_reply__failed_wit, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_link_fuse_reply__failed_wit, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_link_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_kp_u_fuse_link_fuse_reply__failed_wit); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_19, __pyx_kp_u_fuse_link_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_19, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 314, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":313 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":295 * * * cdef void fuse_open (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_open", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":316 * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_read (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_read(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, size_t __pyx_v_size, off_t __pyx_v_off, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; Py_buffer __pyx_v_pybuf; PyObject *__pyx_v_buf = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_read", 0); /* "src/handlers.pxi":321 * cdef Py_buffer pybuf * * try: # <<<<<<<<<<<<<< * with lock: * buf = operations.read(fi.fh, off, size) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":322 * * try: * with lock: # <<<<<<<<<<<<<< * buf = operations.read(fi.fh, off, size) * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 322, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 322, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 322, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 322, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 322, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":323 * try: * with lock: * buf = operations.read(fi.fh, off, size) # <<<<<<<<<<<<<< * * PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_read); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_off_t(__pyx_v_off); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = __Pyx_PyInt_FromSize_t(__pyx_v_size); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 3+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_13, __pyx_t_7, __pyx_t_8, __pyx_t_12}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 3+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif { __pyx_t_15 = PyTuple_New(3+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_t_12); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 323, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_buf = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":322 * * try: * with lock: # <<<<<<<<<<<<<< * buf = operations.read(fi.fh, off, size) * */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_read", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_15) < 0) __PYX_ERR(1, 322, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_15); __pyx_t_12 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_15); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 322, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 322, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 322, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_15); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 322, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__19, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 322, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":325 * buf = operations.read(fi.fh, off, size) * * PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) # <<<<<<<<<<<<<< * with nogil: * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) */ if (unlikely(!__pyx_v_buf)) { __Pyx_RaiseUnboundLocalError("buf"); __PYX_ERR(1, 325, __pyx_L3_error) } __pyx_t_14 = PyObject_GetBuffer(__pyx_v_buf, (&__pyx_v_pybuf), PyBUF_CONTIG_RO); if (unlikely(__pyx_t_14 == -1)) __PYX_ERR(1, 325, __pyx_L3_error) /* "src/handlers.pxi":326 * * PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) * with nogil: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) * PyBuffer_Release(&pybuf) */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/handlers.pxi":327 * PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) * with nogil: * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) # <<<<<<<<<<<<<< * PyBuffer_Release(&pybuf) * except FUSEError as e: */ __pyx_v_ret = fuse_reply_buf(__pyx_v_req, ((const char *)__pyx_v_pybuf.buf), ((size_t)__pyx_v_pybuf.len)); } /* "src/handlers.pxi":326 * * PyObject_GetBuffer(buf, &pybuf, PyBUF_CONTIG_RO) * with nogil: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) * PyBuffer_Release(&pybuf) */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L33; } __pyx_L33:; } } /* "src/handlers.pxi":328 * with nogil: * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) * PyBuffer_Release(&pybuf) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ PyBuffer_Release((&__pyx_v_pybuf)); /* "src/handlers.pxi":321 * cdef Py_buffer pybuf * * try: # <<<<<<<<<<<<<< * with lock: * buf = operations.read(fi.fh, off, size) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":329 * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) * PyBuffer_Release(&pybuf) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_read", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 329, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":330 * PyBuffer_Release(&pybuf) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 330, __pyx_L39_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_12); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 330, __pyx_L39_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":329 * ret = fuse_reply_buf(req, pybuf.buf, pybuf.len) * PyBuffer_Release(&pybuf) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L40; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L39_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_14 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L40:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":331 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_read", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_15) < 0) __PYX_ERR(1, 331, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":332 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":321 * cdef Py_buffer pybuf * * try: # <<<<<<<<<<<<<< * with lock: * buf = operations.read(fi.fh, off, size) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":334 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":335 * * if ret != 0: * log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_write (fuse_req_t req, fuse_ino_t ino, const_char *buf, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_12 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_read_fuse_reply__failed_wit, __pyx_t_6}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_read_fuse_reply__failed_wit, __pyx_t_6}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_read_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_kp_u_fuse_read_fuse_reply__failed_wit); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_19, __pyx_kp_u_fuse_read_fuse_reply__failed_wit); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_19, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 335, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":334 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":316 * log.error('fuse_link(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_read (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_read", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_buf); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":337 * log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_write (fuse_req_t req, fuse_ino_t ino, const_char *buf, # <<<<<<<<<<<<<< * size_t size, off_t off, fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_write(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, const char *__pyx_v_buf, size_t __pyx_v_size, off_t __pyx_v_off, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; size_t __pyx_v_len_; PyObject *__pyx_v_pbuf = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; int __pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; size_t __pyx_t_16; PyObject *__pyx_t_17 = NULL; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_write", 0); /* "src/handlers.pxi":342 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":343 * * try: * if size > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * pbuf = PyBytes_FromStringAndSize(buf, size) */ __pyx_t_4 = ((__pyx_v_size > PY_SSIZE_T_MAX) != 0); if (__pyx_t_4) { /* "src/handlers.pxi":344 * try: * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * pbuf = PyBytes_FromStringAndSize(buf, size) * */ __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_OverflowError, __pyx_tuple__20, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 344, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_Raise(__pyx_t_5, 0, 0, 0); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(1, 344, __pyx_L3_error) /* "src/handlers.pxi":343 * * try: * if size > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * pbuf = PyBytes_FromStringAndSize(buf, size) */ } /* "src/handlers.pxi":345 * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') * pbuf = PyBytes_FromStringAndSize(buf, size) # <<<<<<<<<<<<<< * * # `with` statement may theoretically swallow exception, so we have to */ __pyx_t_5 = PyBytes_FromStringAndSize(__pyx_v_buf, ((Py_ssize_t)__pyx_v_size)); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 345, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_v_pbuf = ((PyObject*)__pyx_t_5); __pyx_t_5 = 0; /* "src/handlers.pxi":350 * # initialize len_ to prevent gcc warning about it potentially * # not initialized. * len_ = 0 # <<<<<<<<<<<<<< * with lock: * len_ = operations.write(fi.fh, off, pbuf) */ __pyx_v_len_ = 0; /* "src/handlers.pxi":351 * # not initialized. * len_ = 0 * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) */ /*with:*/ { __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 351, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = __Pyx_PyObject_LookupSpecial(__pyx_t_5, __pyx_n_s_exit); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 351, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = __Pyx_PyObject_LookupSpecial(__pyx_t_5, __pyx_n_s_enter); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 351, __pyx_L12_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_9 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8); if (likely(__pyx_t_9)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_8, function); } } if (__pyx_t_9) { __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_9); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 351, __pyx_L12_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else { __pyx_t_7 = __Pyx_PyObject_CallNoArg(__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 351, __pyx_L12_error) } __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_12); /*try:*/ { /* "src/handlers.pxi":352 * len_ = 0 * with lock: * len_ = operations.write(fi.fh, off, pbuf) # <<<<<<<<<<<<<< * ret = fuse_reply_write(req, len_) * except FUSEError as e: */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_write); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_9 = __Pyx_PyInt_From_off_t(__pyx_v_off); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[4] = {__pyx_t_13, __pyx_t_8, __pyx_t_9, __pyx_v_pbuf}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_14, 3+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[4] = {__pyx_t_13, __pyx_t_8, __pyx_t_9, __pyx_v_pbuf}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_14, 3+__pyx_t_14); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif { __pyx_t_15 = PyTuple_New(3+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_t_9); __Pyx_INCREF(__pyx_v_pbuf); __Pyx_GIVEREF(__pyx_v_pbuf); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_v_pbuf); __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_15, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_16 = __Pyx_PyInt_As_size_t(__pyx_t_5); if (unlikely((__pyx_t_16 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 352, __pyx_L18_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_v_len_ = __pyx_t_16; /* "src/handlers.pxi":351 * # not initialized. * len_ = 0 * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) */ } __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L25_try_end; __pyx_L18_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_write", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_7, &__pyx_t_15) < 0) __PYX_ERR(1, 351, __pyx_L20_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_15); __pyx_t_9 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_7, __pyx_t_15); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 351, __pyx_L20_except_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_9, NULL); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 351, __pyx_L20_except_error) __Pyx_GOTREF(__pyx_t_17); __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_17); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; if (__pyx_t_4 < 0) __PYX_ERR(1, 351, __pyx_L20_except_error) __pyx_t_18 = ((!(__pyx_t_4 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_5, __pyx_t_7, __pyx_t_15); __pyx_t_5 = 0; __pyx_t_7 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 351, __pyx_L20_except_error) } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L19_exception_handled; } __pyx_L20_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); goto __pyx_L3_error; __pyx_L19_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12); __pyx_L25_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_6) { __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__21, NULL); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 351, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } goto __pyx_L17; } __pyx_L17:; } goto __pyx_L29; __pyx_L12_error:; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L3_error; __pyx_L29:; } /* "src/handlers.pxi":353 * with lock: * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_write(__pyx_v_req, __pyx_v_len_); /* "src/handlers.pxi":342 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":354 * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_write", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_7, &__pyx_t_5) < 0) __PYX_ERR(1, 354, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_v_e = __pyx_t_7; /*try:*/ { /* "src/handlers.pxi":355 * ret = fuse_reply_write(req, len_) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 355, __pyx_L35_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_9); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 355, __pyx_L35_error) __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":354 * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L36; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L35_error:; __pyx_t_6 = 0; __pyx_t_12 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_17 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_10, &__pyx_t_17, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_6, &__pyx_t_12, &__pyx_t_11) < 0)) __Pyx_ErrFetch(&__pyx_t_6, &__pyx_t_12, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_6); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_14 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_17, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ErrRestore(__pyx_t_6, __pyx_t_12, __pyx_t_11); __pyx_t_6 = 0; __pyx_t_12 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_17 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L36:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":356 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_write", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_7, &__pyx_t_15) < 0) __PYX_ERR(1, 356, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":357 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":342 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":359 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":360 * * if ret != 0: * log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_write_buf(fuse_req_t req, fuse_ino_t ino, fuse_bufvec *bufv, */ __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_error); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_5); if (likely(__pyx_t_9)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_5, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_fuse_write_fuse_reply__failed_wi, __pyx_t_7}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_fuse_write_fuse_reply__failed_wi, __pyx_t_7}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_9); __pyx_t_9 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_write_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_write_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_19, __pyx_kp_u_fuse_write_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_19, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 360, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":359 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":337 * log.error('fuse_read(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_write (fuse_req_t req, fuse_ino_t ino, const_char *buf, # <<<<<<<<<<<<<< * size_t size, off_t off, fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_write", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_pbuf); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":362 * log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_write_buf(fuse_req_t req, fuse_ino_t ino, fuse_bufvec *bufv, # <<<<<<<<<<<<<< * off_t off, fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_write_buf(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, struct fuse_bufvec *__pyx_v_bufv, off_t __pyx_v_off, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; size_t __pyx_v_len_; PyObject *__pyx_v_buf = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; size_t __pyx_t_15; PyObject *__pyx_t_16 = NULL; int __pyx_t_17; int __pyx_t_18; int __pyx_t_19; char const *__pyx_t_20; PyObject *__pyx_t_21 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_write_buf", 0); /* "src/handlers.pxi":367 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * # `with` statement may theoretically swallow exception, so we have to * # initialize len_ to prevent gcc warning about it potentially */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":371 * # initialize len_ to prevent gcc warning about it potentially * # not initialized. * len_ = 0 # <<<<<<<<<<<<<< * * buf = PyBytes_from_bufvec(bufv) */ __pyx_v_len_ = 0; /* "src/handlers.pxi":373 * len_ = 0 * * buf = PyBytes_from_bufvec(bufv) # <<<<<<<<<<<<<< * with lock: * len_ = operations.write(fi.fh, off, buf) */ __pyx_t_4 = __pyx_f_6llfuse_PyBytes_from_bufvec(__pyx_v_bufv); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 373, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_buf = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":374 * * buf = PyBytes_from_bufvec(bufv) * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 374, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 374, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 374, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 374, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 374, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":375 * buf = PyBytes_from_bufvec(bufv) * with lock: * len_ = operations.write(fi.fh, off, buf) # <<<<<<<<<<<<<< * ret = fuse_reply_write(req, len_) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_write); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_off_t(__pyx_v_off); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_buf}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_buf}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(3+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __Pyx_INCREF(__pyx_v_buf); __Pyx_GIVEREF(__pyx_v_buf); PyTuple_SET_ITEM(__pyx_t_14, 2+__pyx_t_13, __pyx_v_buf); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_15 = __Pyx_PyInt_As_size_t(__pyx_t_4); if (unlikely((__pyx_t_15 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 375, __pyx_L17_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_len_ = __pyx_t_15; /* "src/handlers.pxi":374 * * buf = PyBytes_from_bufvec(bufv) * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_write_buf", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 374, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 374, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 374, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_17 < 0) __PYX_ERR(1, 374, __pyx_L19_except_error) __pyx_t_18 = ((!(__pyx_t_17 != 0)) != 0); if (__pyx_t_18) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 374, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__22, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 374, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":376 * with lock: * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_write(__pyx_v_req, __pyx_v_len_); /* "src/handlers.pxi":367 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * # `with` statement may theoretically swallow exception, so we have to * # initialize len_ to prevent gcc warning about it potentially */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":377 * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_write_buf", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 377, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":378 * ret = fuse_reply_write(req, len_) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 378, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 378, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":377 * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_16, &__pyx_t_21); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_21); __pyx_t_13 = __pyx_lineno; __pyx_t_19 = __pyx_clineno; __pyx_t_20 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_21); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_16, __pyx_t_21); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_16 = 0; __pyx_t_21 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_19; __pyx_filename = __pyx_t_20; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":379 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_write_buf", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 379, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":380 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":367 * cdef size_t len_ * * try: # <<<<<<<<<<<<<< * # `with` statement may theoretically swallow exception, so we have to * # initialize len_ to prevent gcc warning about it potentially */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":382 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_18 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":383 * * if ret != 0: * log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_flush (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_19 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_19 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_write_buf_fuse_reply__faile, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_write_buf_fuse_reply__faile, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_19, 2+__pyx_t_19); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_19); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_write_buf_fuse_reply__faile); __Pyx_GIVEREF(__pyx_kp_u_fuse_write_buf_fuse_reply__faile); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_19, __pyx_kp_u_fuse_write_buf_fuse_reply__faile); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_19, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 383, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":382 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":362 * log.error('fuse_write(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_write_buf(fuse_req_t req, fuse_ino_t ino, fuse_bufvec *bufv, # <<<<<<<<<<<<<< * off_t off, fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_write_buf", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_buf); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":385 * log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_flush (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_flush(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_flush", 0); /* "src/handlers.pxi":388 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.flush(fi.fh) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":389 * * try: * with lock: # <<<<<<<<<<<<<< * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 389, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 389, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 389, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 389, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 389, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":390 * try: * with lock: * operations.flush(fi.fh) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_flush); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_8) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_12 = PyTuple_New(1+1); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_8); __pyx_t_8 = NULL; __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_12, 0+1, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_12, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 390, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":389 * * try: * with lock: # <<<<<<<<<<<<<< * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_flush", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 389, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_12); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 389, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 389, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (__pyx_t_14 < 0) __PYX_ERR(1, 389, __pyx_L19_except_error) __pyx_t_15 = ((!(__pyx_t_14 != 0)) != 0); if (__pyx_t_15) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_12); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_12 = 0; __PYX_ERR(1, 389, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__23, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 389, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":391 * with lock: * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":388 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.flush(fi.fh) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":392 * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_16 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_16) { __Pyx_AddTraceback("llfuse.fuse_flush", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_12, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 392, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":393 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 393, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_16 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_16 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 393, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_16); } /* "src/handlers.pxi":392 * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_13, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_16 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_13, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_16; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":394 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_flush", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 394, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); /* "src/handlers.pxi":395 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":388 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.flush(fi.fh) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":397 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_15 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_15) { /* "src/handlers.pxi":398 * * if ret != 0: * log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_release (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_flush_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_12 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_flush_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_12 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_flush_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_flush_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_flush_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 398, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":397 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":385 * log.error('fuse_write_buf(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_flush (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_WriteUnraisable("llfuse.fuse_flush", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":400 * log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_release (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_release(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_release", 0); /* "src/handlers.pxi":403 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.release(fi.fh) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":404 * * try: * with lock: # <<<<<<<<<<<<<< * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 404, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 404, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 404, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 404, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 404, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":405 * try: * with lock: * operations.release(fi.fh) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_release); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_8) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_12 = PyTuple_New(1+1); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_8); __pyx_t_8 = NULL; __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_12, 0+1, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_12, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 405, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":404 * * try: * with lock: # <<<<<<<<<<<<<< * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_release", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 404, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_12); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 404, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 404, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (__pyx_t_14 < 0) __PYX_ERR(1, 404, __pyx_L19_except_error) __pyx_t_15 = ((!(__pyx_t_14 != 0)) != 0); if (__pyx_t_15) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_12); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_12 = 0; __PYX_ERR(1, 404, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__24, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 404, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":406 * with lock: * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":403 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.release(fi.fh) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":407 * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_16 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_16) { __Pyx_AddTraceback("llfuse.fuse_release", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_12, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 407, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":408 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 408, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_16 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_16 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 408, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_16); } /* "src/handlers.pxi":407 * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_13, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_16 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_13, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_16; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":409 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_release", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 409, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); /* "src/handlers.pxi":410 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":403 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.release(fi.fh) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":412 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_15 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_15) { /* "src/handlers.pxi":413 * * if ret != 0: * log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_fsync (fuse_req_t req, fuse_ino_t ino, int datasync, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_release_fuse_reply__failed, __pyx_t_6}; __pyx_t_12 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_release_fuse_reply__failed, __pyx_t_6}; __pyx_t_12 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_release_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_release_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_release_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":412 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":400 * log.error('fuse_flush(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_release (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_WriteUnraisable("llfuse.fuse_release", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":415 * log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_fsync (fuse_req_t req, fuse_ino_t ino, int datasync, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_fsync(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, int __pyx_v_datasync, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_fsync", 0); /* "src/handlers.pxi":419 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsync(fi.fh, datasync != 0) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":420 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 420, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 420, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 420, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 420, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 420, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":421 * try: * with lock: * operations.fsync(fi.fh, datasync != 0) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_fsync); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyBool_FromLong((__pyx_v_datasync != 0)); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(2+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 421, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":420 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_fsync", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 420, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 420, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 420, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 420, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 420, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__25, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 420, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":422 * with lock: * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":419 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsync(fi.fh, datasync != 0) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":423 * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_fsync", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 423, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":424 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 424, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 424, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":423 * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_13 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":425 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_fsync", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 425, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":426 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":419 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsync(fi.fh, datasync != 0) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":428 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":429 * * if ret != 0: * log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_opendir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_fsync_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_fsync_fuse_reply__failed_wi, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_fsync_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_kp_u_fuse_fsync_fuse_reply__failed_wi); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_18, __pyx_kp_u_fuse_fsync_fuse_reply__failed_wi); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":428 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":415 * log.error('fuse_release(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_fsync (fuse_req_t req, fuse_ino_t ino, int datasync, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_fsync", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":431 * log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_opendir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_opendir(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; uint64_t __pyx_t_14; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_opendir", 0); /* "src/handlers.pxi":434 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":435 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * fi.fh = operations.opendir(ino, ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 435, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":436 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.opendir(ino, ctx) * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 436, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 436, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 436, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 436, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 436, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":437 * ctx = get_request_context(req) * with lock: * fi.fh = operations.opendir(ino, ctx) # <<<<<<<<<<<<<< * * ret = fuse_reply_open(req, fi) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_opendir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyInt_As_uint64_t(__pyx_t_4); if (unlikely((__pyx_t_14 == ((uint64_t)-1)) && PyErr_Occurred())) __PYX_ERR(1, 437, __pyx_L17_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_fi->fh = __pyx_t_14; /* "src/handlers.pxi":436 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.opendir(ino, ctx) * */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_opendir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 436, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 436, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 436, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 436, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_13); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 436, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__26, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 436, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":439 * fi.fh = operations.opendir(ino, ctx) * * ret = fuse_reply_open(req, fi) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_open(__pyx_v_req, __pyx_v_fi); /* "src/handlers.pxi":434 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":440 * * ret = fuse_reply_open(req, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_opendir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 440, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":441 * ret = fuse_reply_open(req, fi) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 441, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 441, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":440 * * ret = fuse_reply_open(req, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_12 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":442 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_opendir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 442, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":443 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":434 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":445 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":446 * * if ret != 0: * log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_readdir (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_opendir_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_opendir_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_opendir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_opendir_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_18, __pyx_kp_u_fuse_opendir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 446, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":445 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":431 * log.error('fuse_fsync(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_opendir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_opendir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":448 * log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_readdir (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_readdir(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, size_t __pyx_v_size, off_t __pyx_v_off, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; char *__pyx_v_cname; char *__pyx_v_buf; size_t __pyx_v_len_; size_t __pyx_v_acc_size; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_attr = NULL; PyObject *__pyx_v_next_ = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; Py_ssize_t __pyx_t_15; PyObject *(*__pyx_t_16)(PyObject *); PyObject *(*__pyx_t_17)(PyObject *); int __pyx_t_18; void *__pyx_t_19; char *__pyx_t_20; off_t __pyx_t_21; PyObject *__pyx_t_22 = NULL; int __pyx_t_23; int __pyx_t_24; char const *__pyx_t_25; PyObject *__pyx_t_26 = NULL; char const *__pyx_t_27; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_readdir", 0); /* "src/handlers.pxi":456 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * acc_size = 0 * buf = NULL */ /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":457 * * try: * acc_size = 0 # <<<<<<<<<<<<<< * buf = NULL * with lock: */ __pyx_v_acc_size = 0; /* "src/handlers.pxi":458 * try: * acc_size = 0 * buf = NULL # <<<<<<<<<<<<<< * with lock: * for (name, attr, next_) in operations.readdir(fi.fh, off): */ __pyx_v_buf = NULL; /* "src/handlers.pxi":459 * acc_size = 0 * buf = NULL * with lock: # <<<<<<<<<<<<<< * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 459, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 459, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 459, __pyx_L14_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 459, __pyx_L14_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 459, __pyx_L14_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":460 * buf = NULL * with lock: * for (name, attr, next_) in operations.readdir(fi.fh, off): # <<<<<<<<<<<<<< * entry = attr * if buf == NULL: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_readdir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_off_t(__pyx_v_off); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(2+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (likely(PyList_CheckExact(__pyx_t_4)) || PyTuple_CheckExact(__pyx_t_4)) { __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __pyx_t_15 = 0; __pyx_t_16 = NULL; } else { __pyx_t_15 = -1; __pyx_t_6 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_16 = Py_TYPE(__pyx_t_6)->tp_iternext; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 460, __pyx_L20_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; for (;;) { if (likely(!__pyx_t_16)) { if (likely(PyList_CheckExact(__pyx_t_6))) { if (__pyx_t_15 >= PyList_GET_SIZE(__pyx_t_6)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_4 = PyList_GET_ITEM(__pyx_t_6, __pyx_t_15); __Pyx_INCREF(__pyx_t_4); __pyx_t_15++; if (unlikely(0 < 0)) __PYX_ERR(1, 460, __pyx_L20_error) #else __pyx_t_4 = PySequence_ITEM(__pyx_t_6, __pyx_t_15); __pyx_t_15++; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_4); #endif } else { if (__pyx_t_15 >= PyTuple_GET_SIZE(__pyx_t_6)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_6, __pyx_t_15); __Pyx_INCREF(__pyx_t_4); __pyx_t_15++; if (unlikely(0 < 0)) __PYX_ERR(1, 460, __pyx_L20_error) #else __pyx_t_4 = PySequence_ITEM(__pyx_t_6, __pyx_t_15); __pyx_t_15++; if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_4); #endif } } else { __pyx_t_4 = __pyx_t_16(__pyx_t_6); if (unlikely(!__pyx_t_4)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(1, 460, __pyx_L20_error) } break; } __Pyx_GOTREF(__pyx_t_4); } if ((likely(PyTuple_CheckExact(__pyx_t_4))) || (PyList_CheckExact(__pyx_t_4))) { PyObject* sequence = __pyx_t_4; #if !CYTHON_COMPILING_IN_PYPY Py_ssize_t size = Py_SIZE(sequence); #else Py_ssize_t size = PySequence_Size(sequence); #endif if (unlikely(size != 3)) { if (size > 3) __Pyx_RaiseTooManyValuesError(3); else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size); __PYX_ERR(1, 460, __pyx_L20_error) } #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (likely(PyTuple_CheckExact(sequence))) { __pyx_t_14 = PyTuple_GET_ITEM(sequence, 0); __pyx_t_8 = PyTuple_GET_ITEM(sequence, 1); __pyx_t_7 = PyTuple_GET_ITEM(sequence, 2); } else { __pyx_t_14 = PyList_GET_ITEM(sequence, 0); __pyx_t_8 = PyList_GET_ITEM(sequence, 1); __pyx_t_7 = PyList_GET_ITEM(sequence, 2); } __Pyx_INCREF(__pyx_t_14); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(__pyx_t_7); #else __pyx_t_14 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_7 = PySequence_ITEM(sequence, 2); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_7); #endif __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { Py_ssize_t index = -1; __pyx_t_12 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 460, __pyx_L20_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_17 = Py_TYPE(__pyx_t_12)->tp_iternext; index = 0; __pyx_t_14 = __pyx_t_17(__pyx_t_12); if (unlikely(!__pyx_t_14)) goto __pyx_L30_unpacking_failed; __Pyx_GOTREF(__pyx_t_14); index = 1; __pyx_t_8 = __pyx_t_17(__pyx_t_12); if (unlikely(!__pyx_t_8)) goto __pyx_L30_unpacking_failed; __Pyx_GOTREF(__pyx_t_8); index = 2; __pyx_t_7 = __pyx_t_17(__pyx_t_12); if (unlikely(!__pyx_t_7)) goto __pyx_L30_unpacking_failed; __Pyx_GOTREF(__pyx_t_7); if (__Pyx_IternextUnpackEndCheck(__pyx_t_17(__pyx_t_12), 3) < 0) __PYX_ERR(1, 460, __pyx_L20_error) __pyx_t_17 = NULL; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L31_unpacking_done; __pyx_L30_unpacking_failed:; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_t_17 = NULL; if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); __PYX_ERR(1, 460, __pyx_L20_error) __pyx_L31_unpacking_done:; } __Pyx_XDECREF_SET(__pyx_v_name, __pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF_SET(__pyx_v_attr, __pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF_SET(__pyx_v_next_, __pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":461 * with lock: * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr # <<<<<<<<<<<<<< * if buf == NULL: * buf = calloc_or_raise(size, sizeof(char)) */ if (!(likely(__Pyx_TypeTest(__pyx_v_attr, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 461, __pyx_L20_error) __pyx_t_4 = __pyx_v_attr; __Pyx_INCREF(__pyx_t_4); __Pyx_XDECREF_SET(__pyx_v_entry, ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_4)); __pyx_t_4 = 0; /* "src/handlers.pxi":462 * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr * if buf == NULL: # <<<<<<<<<<<<<< * buf = calloc_or_raise(size, sizeof(char)) * cname = PyBytes_AsString(name) */ __pyx_t_18 = ((__pyx_v_buf == NULL) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":463 * entry = attr * if buf == NULL: * buf = calloc_or_raise(size, sizeof(char)) # <<<<<<<<<<<<<< * cname = PyBytes_AsString(name) * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, */ __pyx_t_19 = __pyx_f_6llfuse_calloc_or_raise(__pyx_v_size, (sizeof(char))); if (unlikely(__pyx_t_19 == NULL)) __PYX_ERR(1, 463, __pyx_L20_error) __pyx_v_buf = ((char *)__pyx_t_19); /* "src/handlers.pxi":462 * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr * if buf == NULL: # <<<<<<<<<<<<<< * buf = calloc_or_raise(size, sizeof(char)) * cname = PyBytes_AsString(name) */ } /* "src/handlers.pxi":464 * if buf == NULL: * buf = calloc_or_raise(size, sizeof(char)) * cname = PyBytes_AsString(name) # <<<<<<<<<<<<<< * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, * cname, entry.attr, next_) */ __pyx_t_20 = PyBytes_AsString(__pyx_v_name); if (unlikely(__pyx_t_20 == NULL)) __PYX_ERR(1, 464, __pyx_L20_error) __pyx_v_cname = __pyx_t_20; /* "src/handlers.pxi":466 * cname = PyBytes_AsString(name) * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, * cname, entry.attr, next_) # <<<<<<<<<<<<<< * if len_ > (size - acc_size): * break */ __pyx_t_21 = __Pyx_PyInt_As_off_t(__pyx_v_next_); if (unlikely((__pyx_t_21 == ((off_t)-1)) && PyErr_Occurred())) __PYX_ERR(1, 466, __pyx_L20_error) /* "src/handlers.pxi":465 * buf = calloc_or_raise(size, sizeof(char)) * cname = PyBytes_AsString(name) * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, # <<<<<<<<<<<<<< * cname, entry.attr, next_) * if len_ > (size - acc_size): */ __pyx_v_len_ = fuse_add_direntry(__pyx_v_req, (__pyx_v_buf + __pyx_v_acc_size), (__pyx_v_size - __pyx_v_acc_size), __pyx_v_cname, __pyx_v_entry->attr, __pyx_t_21); /* "src/handlers.pxi":467 * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, * cname, entry.attr, next_) * if len_ > (size - acc_size): # <<<<<<<<<<<<<< * break * acc_size += len_ */ __pyx_t_18 = ((__pyx_v_len_ > (__pyx_v_size - __pyx_v_acc_size)) != 0); if (__pyx_t_18) { /* "src/handlers.pxi":468 * cname, entry.attr, next_) * if len_ > (size - acc_size): * break # <<<<<<<<<<<<<< * acc_size += len_ * ret = fuse_reply_buf(req, buf, acc_size) */ goto __pyx_L29_break; /* "src/handlers.pxi":467 * len_ = fuse_add_direntry(req, buf + acc_size, size - acc_size, * cname, entry.attr, next_) * if len_ > (size - acc_size): # <<<<<<<<<<<<<< * break * acc_size += len_ */ } /* "src/handlers.pxi":469 * if len_ > (size - acc_size): * break * acc_size += len_ # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, buf, acc_size) * except FUSEError as e: */ __pyx_v_acc_size = (__pyx_v_acc_size + __pyx_v_len_); /* "src/handlers.pxi":460 * buf = NULL * with lock: * for (name, attr, next_) in operations.readdir(fi.fh, off): # <<<<<<<<<<<<<< * entry = attr * if buf == NULL: */ } __pyx_L29_break:; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":459 * acc_size = 0 * buf = NULL * with lock: # <<<<<<<<<<<<<< * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L27_try_end; __pyx_L20_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_readdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_7) < 0) __PYX_ERR(1, 459, __pyx_L22_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_7); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 459, __pyx_L22_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_22 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_22)) __PYX_ERR(1, 459, __pyx_L22_except_error) __Pyx_GOTREF(__pyx_t_22); __pyx_t_18 = __Pyx_PyObject_IsTrue(__pyx_t_22); __Pyx_DECREF(__pyx_t_22); __pyx_t_22 = 0; if (__pyx_t_18 < 0) __PYX_ERR(1, 459, __pyx_L22_except_error) __pyx_t_23 = ((!(__pyx_t_18 != 0)) != 0); if (__pyx_t_23) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_7); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_7 = 0; __PYX_ERR(1, 459, __pyx_L22_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L21_exception_handled; } __pyx_L22_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L6_error; __pyx_L21_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L27_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__27, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 459, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L19; } __pyx_L19:; } goto __pyx_L37; __pyx_L14_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L6_error; __pyx_L37:; } /* "src/handlers.pxi":470 * break * acc_size += len_ * ret = fuse_reply_buf(req, buf, acc_size) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_buf(__pyx_v_req, __pyx_v_buf, __pyx_v_acc_size); /* "src/handlers.pxi":456 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * acc_size = 0 * buf = NULL */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L13_try_end; __pyx_L6_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":471 * acc_size += len_ * ret = fuse_reply_buf(req, buf, acc_size) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_readdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 471, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":472 * ret = fuse_reply_buf(req, buf, acc_size) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 472, __pyx_L43_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 472, __pyx_L43_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":471 * acc_size += len_ * ret = fuse_reply_buf(req, buf, acc_size) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L44; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L43_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_22 = 0; __pyx_t_26 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_22, &__pyx_t_26); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_22); __Pyx_XGOTREF(__pyx_t_26); __pyx_t_13 = __pyx_lineno; __pyx_t_24 = __pyx_clineno; __pyx_t_25 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_22); __Pyx_XGIVEREF(__pyx_t_26); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_22, __pyx_t_26); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_22 = 0; __pyx_t_26 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_24; __pyx_filename = __pyx_t_25; goto __pyx_L8_except_error; } __pyx_L44:; } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L7_exception_handled; } /* "src/handlers.pxi":473 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * finally: */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_readdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_7) < 0) __PYX_ERR(1, 473, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_7); /* "src/handlers.pxi":474 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * finally: * if buf != NULL: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L7_exception_handled; } __pyx_L8_except_error:; /* "src/handlers.pxi":456 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * acc_size = 0 * buf = NULL */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L4_error; __pyx_L7_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L13_try_end:; } } /* "src/handlers.pxi":476 * ret = handle_exc(req) * finally: * if buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(buf) * */ /*finally:*/ { /*normal exit:*/{ __pyx_t_23 = ((__pyx_v_buf != NULL) != 0); if (__pyx_t_23) { /* "src/handlers.pxi":477 * finally: * if buf != NULL: * stdlib.free(buf) # <<<<<<<<<<<<<< * * if ret != 0: */ free(__pyx_v_buf); /* "src/handlers.pxi":476 * ret = handle_exc(req) * finally: * if buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(buf) * */ } goto __pyx_L5; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L4_error:; __pyx_t_3 = 0; __pyx_t_2 = 0; __pyx_t_1 = 0; __pyx_t_26 = 0; __pyx_t_22 = 0; __pyx_t_9 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_26, &__pyx_t_22, &__pyx_t_9); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_3, &__pyx_t_2, &__pyx_t_1) < 0)) __Pyx_ErrFetch(&__pyx_t_3, &__pyx_t_2, &__pyx_t_1); __Pyx_XGOTREF(__pyx_t_3); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_26); __Pyx_XGOTREF(__pyx_t_22); __Pyx_XGOTREF(__pyx_t_9); __pyx_t_24 = __pyx_lineno; __pyx_t_13 = __pyx_clineno; __pyx_t_27 = __pyx_filename; { __pyx_t_23 = ((__pyx_v_buf != NULL) != 0); if (__pyx_t_23) { /* "src/handlers.pxi":477 * finally: * if buf != NULL: * stdlib.free(buf) # <<<<<<<<<<<<<< * * if ret != 0: */ free(__pyx_v_buf); /* "src/handlers.pxi":476 * ret = handle_exc(req) * finally: * if buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(buf) * */ } } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_26); __Pyx_XGIVEREF(__pyx_t_22); __Pyx_XGIVEREF(__pyx_t_9); __Pyx_ExceptionReset(__pyx_t_26, __pyx_t_22, __pyx_t_9); } __Pyx_XGIVEREF(__pyx_t_3); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_1); __Pyx_ErrRestore(__pyx_t_3, __pyx_t_2, __pyx_t_1); __pyx_t_3 = 0; __pyx_t_2 = 0; __pyx_t_1 = 0; __pyx_t_26 = 0; __pyx_t_22 = 0; __pyx_t_9 = 0; __pyx_lineno = __pyx_t_24; __pyx_clineno = __pyx_t_13; __pyx_filename = __pyx_t_27; goto __pyx_L1_error; } __pyx_L5:; } /* "src/handlers.pxi":479 * stdlib.free(buf) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_23 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_23) { /* "src/handlers.pxi":480 * * if ret != 0: * log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_releasedir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_8 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_readdir_fuse_reply__failed, __pyx_t_4}; __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_readdir_fuse_reply__failed, __pyx_t_4}; __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_14 = PyTuple_New(2+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_readdir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_readdir_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_kp_u_fuse_readdir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 480, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":479 * stdlib.free(buf) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":448 * log.error('fuse_opendir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_readdir (fuse_req_t req, fuse_ino_t ino, size_t size, off_t off, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_readdir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_attr); __Pyx_XDECREF(__pyx_v_next_); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":482 * log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_releasedir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_releasedir(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_releasedir", 0); /* "src/handlers.pxi":485 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.releasedir(fi.fh) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":486 * * try: * with lock: # <<<<<<<<<<<<<< * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 486, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 486, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 486, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 486, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 486, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":487 * try: * with lock: * operations.releasedir(fi.fh) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_releasedir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_8) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_8, __pyx_t_7}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_12 = PyTuple_New(1+1); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_8); __pyx_t_8 = NULL; __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_12, 0+1, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_12, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 487, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":486 * * try: * with lock: # <<<<<<<<<<<<<< * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 486, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_12); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 486, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 486, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_13); __pyx_t_14 = __Pyx_PyObject_IsTrue(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; if (__pyx_t_14 < 0) __PYX_ERR(1, 486, __pyx_L19_except_error) __pyx_t_15 = ((!(__pyx_t_14 != 0)) != 0); if (__pyx_t_15) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_12); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_12 = 0; __PYX_ERR(1, 486, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__28, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 486, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":488 * with lock: * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":485 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.releasedir(fi.fh) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":489 * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_16 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_16) { __Pyx_AddTraceback("llfuse.fuse_releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_12, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 489, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":490 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 490, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_16 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_16 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 490, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_16); } /* "src/handlers.pxi":489 * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_13, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_16 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_13, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_13 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_16; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":491 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_12) < 0) __PYX_ERR(1, 491, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_12); /* "src/handlers.pxi":492 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":485 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.releasedir(fi.fh) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":494 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_releasedir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_15 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_15) { /* "src/handlers.pxi":495 * * if ret != 0: * log.error('fuse_releasedir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_releasedir_fuse_reply__fail, __pyx_t_6}; __pyx_t_12 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_releasedir_fuse_reply__fail, __pyx_t_6}; __pyx_t_12 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_releasedir_fuse_reply__fail); __Pyx_GIVEREF(__pyx_kp_u_fuse_releasedir_fuse_reply__fail); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_releasedir_fuse_reply__fail); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 495, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; /* "src/handlers.pxi":494 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_releasedir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":482 * log.error('fuse_readdir(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_releasedir (fuse_req_t req, fuse_ino_t ino, fuse_file_info *fi) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_WriteUnraisable("llfuse.fuse_releasedir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":498 * * * cdef void fuse_fsyncdir (fuse_req_t req, fuse_ino_t ino, int datasync, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_fsyncdir(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino, int __pyx_v_datasync, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_fsyncdir", 0); /* "src/handlers.pxi":502 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsyncdir(fi.fh, datasync != 0) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":503 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 503, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 503, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 503, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 503, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 503, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":504 * try: * with lock: * operations.fsyncdir(fi.fh, datasync != 0) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_fsyncdir); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_uint64_t(__pyx_v_fi->fh); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyBool_FromLong((__pyx_v_datasync != 0)); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_t_7, __pyx_t_8}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 2+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(2+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 504, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":503 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 503, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 503, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 503, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 503, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 503, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__29, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 503, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":505 * with lock: * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":502 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsyncdir(fi.fh, datasync != 0) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":506 * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 506, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":507 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 507, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 507, __pyx_L34_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":506 * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_13 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":508 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 508, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":509 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":502 * cdef int ret * * try: # <<<<<<<<<<<<<< * with lock: * operations.fsyncdir(fi.fh, datasync != 0) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":511 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_fsyncdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":512 * * if ret != 0: * log.error('fuse_fsyncdir(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_fsyncdir_fuse_reply__failed, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_fsyncdir_fuse_reply__failed, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_fsyncdir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_fsyncdir_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_18, __pyx_kp_u_fuse_fsyncdir_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":511 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_fsyncdir(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":498 * * * cdef void fuse_fsyncdir (fuse_req_t req, fuse_ino_t ino, int datasync, # <<<<<<<<<<<<<< * fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_fsyncdir", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":515 * * * cdef void fuse_statfs (fuse_req_t req, fuse_ino_t ino) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef StatvfsData stats */ static void __pyx_f_6llfuse_fuse_statfs(fuse_req_t __pyx_v_req, CYTHON_UNUSED fuse_ino_t __pyx_v_ino) { int __pyx_v_ret; struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_stats = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; int __pyx_t_14; int __pyx_t_15; int __pyx_t_16; char const *__pyx_t_17; PyObject *__pyx_t_18 = NULL; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_statfs", 0); /* "src/handlers.pxi":520 * * # We don't set all the components * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":521 * # We don't set all the components * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * stats = operations.statfs(ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 521, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":522 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 522, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 522, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 522, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 522, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 522, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":523 * ctx = get_request_context(req) * with lock: * stats = operations.statfs(ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_statfs(req, &stats.stat) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_statfs); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_7) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_v_ctx); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); } else #endif { __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_8, 0+1, __pyx_v_ctx); __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 523, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_StatvfsData)))) __PYX_ERR(1, 523, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_stats = ((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":522 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_statfs", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_8) < 0) __PYX_ERR(1, 522, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_8); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 522, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 522, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (__pyx_t_13 < 0) __PYX_ERR(1, 522, __pyx_L19_except_error) __pyx_t_14 = ((!(__pyx_t_13 != 0)) != 0); if (__pyx_t_14) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_8); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_8); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_8 = 0; __PYX_ERR(1, 522, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__30, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 522, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":524 * with lock: * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_stats)) { __Pyx_RaiseUnboundLocalError("stats"); __PYX_ERR(1, 524, __pyx_L3_error) } __pyx_v_ret = fuse_reply_statfs(__pyx_v_req, (&__pyx_v_stats->stat)); /* "src/handlers.pxi":520 * * # We don't set all the components * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; /* "src/handlers.pxi":525 * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_15 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_15) { __Pyx_AddTraceback("llfuse.fuse_statfs", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 525, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":526 * ret = fuse_reply_statfs(req, &stats.stat) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 526, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_15 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_15 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 526, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_15); } /* "src/handlers.pxi":525 * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_12 = 0; __pyx_t_18 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_12, &__pyx_t_18); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_18); __pyx_t_15 = __pyx_lineno; __pyx_t_16 = __pyx_clineno; __pyx_t_17 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_12, __pyx_t_18); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_12 = 0; __pyx_t_18 = 0; __pyx_lineno = __pyx_t_15; __pyx_clineno = __pyx_t_16; __pyx_filename = __pyx_t_17; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":527 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_statfs", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_8) < 0) __PYX_ERR(1, 527, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_8); /* "src/handlers.pxi":528 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":520 * * # We don't set all the components * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":530 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_14 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_14) { /* "src/handlers.pxi":531 * * if ret != 0: * log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_setxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = NULL; __pyx_t_16 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_16 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_statfs_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_8 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_16, 2+__pyx_t_16); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_statfs_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_8 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_16, 2+__pyx_t_16); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_19 = PyTuple_New(2+__pyx_t_16); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_19); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_19, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_statfs_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_statfs_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_19, 0+__pyx_t_16, __pyx_kp_u_fuse_statfs_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_19, 1+__pyx_t_16, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_19, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 531, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; /* "src/handlers.pxi":530 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":515 * * * cdef void fuse_statfs (fuse_req_t req, fuse_ino_t ino) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef StatvfsData stats */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_19); __Pyx_WriteUnraisable("llfuse.fuse_statfs", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_stats); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":533 * log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_setxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * const_char *cvalue, size_t size, int flags, * uint32_t position) with gil: */ static void __pyx_f_6llfuse_fuse_setxattr_darwin(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, const char *__pyx_v_cname, const char *__pyx_v_cvalue, size_t __pyx_v_size, int __pyx_v_flags, uint32_t __pyx_v_position) { int __pyx_v_ret; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_setxattr_darwin", 0); /* "src/handlers.pxi":538 * cdef int ret * * if position != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) * ret = fuse_reply_err(req, errno.EIO) */ __pyx_t_1 = ((__pyx_v_position != 0) != 0); if (__pyx_t_1) { /* "src/handlers.pxi":539 * * if position != 0: * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: */ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = __Pyx_PyInt_From_uint32_t(__pyx_v_position); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_fuse_setxattr_non_zero_position, __pyx_t_3}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_fuse_setxattr_non_zero_position, __pyx_t_3}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_setxattr_non_zero_position); __Pyx_GIVEREF(__pyx_kp_u_fuse_setxattr_non_zero_position); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_kp_u_fuse_setxattr_non_zero_position); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_t_3); __pyx_t_3 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/handlers.pxi":540 * if position != 0: * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) * ret = fuse_reply_err(req, errno.EIO) # <<<<<<<<<<<<<< * if ret != 0: * log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, EIO); /* "src/handlers.pxi":541 * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) * return */ __pyx_t_1 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_1) { /* "src/handlers.pxi":542 * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: * log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * return * */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_fuse_setxattr_fuse_reply_err_fai, __pyx_t_4}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_fuse_setxattr_fuse_reply_err_fai, __pyx_t_4}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_5 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_3); __pyx_t_3 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_setxattr_fuse_reply_err_fai); __Pyx_GIVEREF(__pyx_kp_u_fuse_setxattr_fuse_reply_err_fai); PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_6, __pyx_kp_u_fuse_setxattr_fuse_reply_err_fai); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_6, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_5, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 542, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/handlers.pxi":541 * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) * return */ } /* "src/handlers.pxi":543 * if ret != 0: * log.error('fuse_setxattr(): fuse_reply_err failed with %s', strerror(-ret)) * return # <<<<<<<<<<<<<< * * # Filter out flags that don't make any sense for a FUSE */ goto __pyx_L0; /* "src/handlers.pxi":538 * cdef int ret * * if position != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): non-zero position (%d) not supported', position) * ret = fuse_reply_err(req, errno.EIO) */ } /* "src/handlers.pxi":549 * # passes through. * # (cf. https://groups.google.com/d/msg/fuse4x/bRnh7J_nsts/Z7raJ06DB4sJ) * flags &= ~(XATTR_NOFOLLOW | XATTR_NODEFAULT | # <<<<<<<<<<<<<< * XATTR_NOSECURITY) * fuse_setxattr(req, ino, cname, cvalue, size, flags) */ __pyx_v_flags = (__pyx_v_flags & (~((XATTR_NOFOLLOW | XATTR_NODEFAULT) | XATTR_NOSECURITY))); /* "src/handlers.pxi":551 * flags &= ~(XATTR_NOFOLLOW | XATTR_NODEFAULT | * XATTR_NOSECURITY) * fuse_setxattr(req, ino, cname, cvalue, size, flags) # <<<<<<<<<<<<<< * * cdef void fuse_setxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, */ __pyx_f_6llfuse_fuse_setxattr(__pyx_v_req, __pyx_v_ino, __pyx_v_cname, __pyx_v_cvalue, __pyx_v_size, __pyx_v_flags); /* "src/handlers.pxi":533 * log.error('fuse_statfs(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_setxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * const_char *cvalue, size_t size, int flags, * uint32_t position) with gil: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_WriteUnraisable("llfuse.fuse_setxattr_darwin", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":553 * fuse_setxattr(req, ino, cname, cvalue, size, flags) * * cdef void fuse_setxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * const_char *cvalue, size_t size, int flags) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_setxattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, const char *__pyx_v_cname, const char *__pyx_v_cvalue, size_t __pyx_v_size, int __pyx_v_flags) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_value = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; int __pyx_t_5; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; PyObject *__pyx_t_17 = NULL; PyObject *__pyx_t_18 = NULL; PyObject *__pyx_t_19 = NULL; int __pyx_t_20; char const *__pyx_t_21; PyObject *__pyx_t_22 = NULL; PyObject *__pyx_t_23 = NULL; PyObject *__pyx_t_24 = NULL; PyObject *__pyx_t_25 = NULL; PyObject *__pyx_t_26 = NULL; PyObject *__pyx_t_27 = NULL; char const *__pyx_t_28; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_setxattr", 0); /* "src/handlers.pxi":557 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":558 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * name = PyBytes_FromString(cname) * if size > PY_SSIZE_T_MAX: */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 558, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":559 * try: * ctx = get_request_context(req) * name = PyBytes_FromString(cname) # <<<<<<<<<<<<<< * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') */ __pyx_t_4 = PyBytes_FromString(__pyx_v_cname); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 559, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":560 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * if size > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * value = PyBytes_FromStringAndSize(cvalue, size) */ __pyx_t_5 = ((__pyx_v_size > PY_SSIZE_T_MAX) != 0); if (__pyx_t_5) { /* "src/handlers.pxi":561 * name = PyBytes_FromString(cname) * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * value = PyBytes_FromStringAndSize(cvalue, size) * */ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OverflowError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 561, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(1, 561, __pyx_L3_error) /* "src/handlers.pxi":560 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * if size > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * value = PyBytes_FromStringAndSize(cvalue, size) */ } /* "src/handlers.pxi":562 * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') * value = PyBytes_FromStringAndSize(cvalue, size) # <<<<<<<<<<<<<< * * # Special case for deadlock debugging */ __pyx_t_4 = PyBytes_FromStringAndSize(__pyx_v_cvalue, ((Py_ssize_t)__pyx_v_size)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 562, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_value = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":565 * * # Special case for deadlock debugging * if ino == FUSE_ROOT_ID and string.strcmp(cname, 'fuse_stacktrace') == 0: # <<<<<<<<<<<<<< * operations.stacktrace() * else: */ __pyx_t_6 = ((__pyx_v_ino == FUSE_ROOT_ID) != 0); if (__pyx_t_6) { } else { __pyx_t_5 = __pyx_t_6; goto __pyx_L13_bool_binop_done; } __pyx_t_6 = ((strcmp(__pyx_v_cname, ((char const *)"fuse_stacktrace")) == 0) != 0); __pyx_t_5 = __pyx_t_6; __pyx_L13_bool_binop_done:; if (__pyx_t_5) { /* "src/handlers.pxi":566 * # Special case for deadlock debugging * if ino == FUSE_ROOT_ID and string.strcmp(cname, 'fuse_stacktrace') == 0: * operations.stacktrace() # <<<<<<<<<<<<<< * else: * if PLATFORM == PLATFORM_DARWIN: */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_stacktrace); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 566, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 566, __pyx_L3_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_4 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 566, __pyx_L3_error) } __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":565 * * # Special case for deadlock debugging * if ino == FUSE_ROOT_ID and string.strcmp(cname, 'fuse_stacktrace') == 0: # <<<<<<<<<<<<<< * operations.stacktrace() * else: */ goto __pyx_L12; } /* "src/handlers.pxi":568 * operations.stacktrace() * else: * if PLATFORM == PLATFORM_DARWIN: # <<<<<<<<<<<<<< * # No known flags * with lock: */ /*else*/ { __pyx_t_5 = ((PLATFORM == PLATFORM_DARWIN) != 0); if (__pyx_t_5) { /* "src/handlers.pxi":570 * if PLATFORM == PLATFORM_DARWIN: * # No known flags * with lock: # <<<<<<<<<<<<<< * operations.setxattr(ino, name, value, ctx) * else: */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 570, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 570, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_8 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 570, __pyx_L16_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_10 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) { __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_8); if (likely(__pyx_t_10)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8); __Pyx_INCREF(__pyx_t_10); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_8, function); } } if (__pyx_t_10) { __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_10); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 570, __pyx_L16_error) __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else { __pyx_t_7 = __Pyx_PyObject_CallNoArg(__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 570, __pyx_L16_error) } __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_11, &__pyx_t_12, &__pyx_t_13); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_13); /*try:*/ { /* "src/handlers.pxi":571 * # No known flags * with lock: * operations.setxattr(ino, name, value, ctx) # <<<<<<<<<<<<<< * else: * # Make sure we know all the flags */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_setxattr); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_10 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_10)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_10); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[5] = {__pyx_t_10, __pyx_t_8, __pyx_v_name, __pyx_v_value, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[5] = {__pyx_t_10, __pyx_t_8, __pyx_v_name, __pyx_v_value, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_14, 4+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_15 = PyTuple_New(4+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_10) { __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_10); __pyx_t_10 = NULL; } __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_8); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_v_name); __Pyx_INCREF(__pyx_v_value); __Pyx_GIVEREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_v_value); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_15, 3+__pyx_t_14, __pyx_v_ctx); __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 571, __pyx_L22_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":570 * if PLATFORM == PLATFORM_DARWIN: * # No known flags * with lock: # <<<<<<<<<<<<<< * operations.setxattr(ino, name, value, ctx) * else: */ } __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L29_try_end; __pyx_L22_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_7, &__pyx_t_15) < 0) __PYX_ERR(1, 570, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_15); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_7, __pyx_t_15); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 570, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_16 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 570, __pyx_L24_except_error) __Pyx_GOTREF(__pyx_t_16); __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_t_16); __Pyx_DECREF(__pyx_t_16); __pyx_t_16 = 0; if (__pyx_t_5 < 0) __PYX_ERR(1, 570, __pyx_L24_except_error) __pyx_t_6 = ((!(__pyx_t_5 != 0)) != 0); if (__pyx_t_6) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_7, __pyx_t_15); __pyx_t_4 = 0; __pyx_t_7 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 570, __pyx_L24_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L23_exception_handled; } __pyx_L24_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ExceptionReset(__pyx_t_11, __pyx_t_12, __pyx_t_13); goto __pyx_L3_error; __pyx_L23_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ExceptionReset(__pyx_t_11, __pyx_t_12, __pyx_t_13); __pyx_L29_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_9) { __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__32, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 570, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } goto __pyx_L21; } __pyx_L21:; } goto __pyx_L33; __pyx_L16_error:; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; goto __pyx_L3_error; __pyx_L33:; } /* "src/handlers.pxi":568 * operations.stacktrace() * else: * if PLATFORM == PLATFORM_DARWIN: # <<<<<<<<<<<<<< * # No known flags * with lock: */ goto __pyx_L15; } /* "src/handlers.pxi":574 * else: * # Make sure we know all the flags * if flags & ~(XATTR_CREATE | XATTR_REPLACE): # <<<<<<<<<<<<<< * raise ValueError('unknown flag(s): %o' % flags) * */ /*else*/ { __pyx_t_6 = ((__pyx_v_flags & (~(XATTR_CREATE | XATTR_REPLACE))) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":575 * # Make sure we know all the flags * if flags & ~(XATTR_CREATE | XATTR_REPLACE): * raise ValueError('unknown flag(s): %o' % flags) # <<<<<<<<<<<<<< * * with lock: */ __pyx_t_15 = __Pyx_PyInt_From_int(__pyx_v_flags); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 575, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_7 = PyUnicode_Format(__pyx_kp_u_unknown_flag_s_o, __pyx_t_15); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 575, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 575, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_15, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 575, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_Raise(__pyx_t_7, 0, 0, 0); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __PYX_ERR(1, 575, __pyx_L3_error) /* "src/handlers.pxi":574 * else: * # Make sure we know all the flags * if flags & ~(XATTR_CREATE | XATTR_REPLACE): # <<<<<<<<<<<<<< * raise ValueError('unknown flag(s): %o' % flags) * */ } /* "src/handlers.pxi":577 * raise ValueError('unknown flag(s): %o' % flags) * * with lock: # <<<<<<<<<<<<<< * if flags & XATTR_CREATE: # Attribute must not exist * try: */ /*with:*/ { __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 577, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_9 = __Pyx_PyObject_LookupSpecial(__pyx_t_7, __pyx_n_s_exit); if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 577, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_7, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 577, __pyx_L35_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_8) { __pyx_t_15 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_8); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 577, __pyx_L35_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_15 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 577, __pyx_L35_error) } __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_13, &__pyx_t_12, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":578 * * with lock: * if flags & XATTR_CREATE: # Attribute must not exist # <<<<<<<<<<<<<< * try: * operations.getxattr(ino, name) */ __pyx_t_6 = ((__pyx_v_flags & XATTR_CREATE) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":579 * with lock: * if flags & XATTR_CREATE: # Attribute must not exist * try: # <<<<<<<<<<<<<< * operations.getxattr(ino, name) * except FUSEError as e: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_16, &__pyx_t_17, &__pyx_t_18); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_18); /*try:*/ { /* "src/handlers.pxi":580 * if flags & XATTR_CREATE: # Attribute must not exist * try: * operations.getxattr(ino, name) # <<<<<<<<<<<<<< * except FUSEError as e: * if e.errno != ENOATTR: */ __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_getxattr); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_4 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_8 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_15))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_15); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_15); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_15, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_4, __pyx_v_name}; __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_4, __pyx_v_name}; __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_10 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_10, 0+__pyx_t_14, __pyx_t_4); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_14, __pyx_v_name); __pyx_t_4 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_15, __pyx_t_10, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 580, __pyx_L50_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":579 * with lock: * if flags & XATTR_CREATE: # Attribute must not exist * try: # <<<<<<<<<<<<<< * operations.getxattr(ino, name) * except FUSEError as e: */ } /* "src/handlers.pxi":585 * raise * else: * raise FUSEError(errno.EEXIST) # <<<<<<<<<<<<<< * * elif flags & XATTR_REPLACE: # Attribute must exist */ /*else:*/ { __pyx_t_7 = __Pyx_PyInt_From_int(EEXIST); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 585, __pyx_L52_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_15 = PyTuple_New(1); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 585, __pyx_L52_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_6llfuse_FUSEError), __pyx_t_15, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 585, __pyx_L52_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_Raise(__pyx_t_7, 0, 0, 0); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __PYX_ERR(1, 585, __pyx_L52_except_error) } __pyx_L50_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/handlers.pxi":581 * try: * operations.getxattr(ino, name) * except FUSEError as e: # <<<<<<<<<<<<<< * if e.errno != ENOATTR: * raise */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_15, &__pyx_t_10) < 0) __PYX_ERR(1, 581, __pyx_L52_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_10); __Pyx_INCREF(__pyx_t_15); __pyx_v_e = __pyx_t_15; /*try:*/ { /* "src/handlers.pxi":582 * operations.getxattr(ino, name) * except FUSEError as e: * if e.errno != ENOATTR: # <<<<<<<<<<<<<< * raise * else: */ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 582, __pyx_L63_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_8 = __Pyx_PyInt_From_int(ENOATTR); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 582, __pyx_L63_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_19 = PyObject_RichCompare(__pyx_t_4, __pyx_t_8, Py_NE); __Pyx_XGOTREF(__pyx_t_19); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 582, __pyx_L63_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_19); if (unlikely(__pyx_t_6 < 0)) __PYX_ERR(1, 582, __pyx_L63_error) __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; if (__pyx_t_6) { /* "src/handlers.pxi":583 * except FUSEError as e: * if e.errno != ENOATTR: * raise # <<<<<<<<<<<<<< * else: * raise FUSEError(errno.EEXIST) */ __Pyx_GIVEREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestoreWithState(__pyx_t_7, __pyx_t_15, __pyx_t_10); __pyx_t_7 = 0; __pyx_t_15 = 0; __pyx_t_10 = 0; __PYX_ERR(1, 583, __pyx_L63_error) /* "src/handlers.pxi":582 * operations.getxattr(ino, name) * except FUSEError as e: * if e.errno != ENOATTR: # <<<<<<<<<<<<<< * raise * else: */ } } /* "src/handlers.pxi":581 * try: * operations.getxattr(ino, name) * except FUSEError as e: # <<<<<<<<<<<<<< * if e.errno != ENOATTR: * raise */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L64; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L63_error:; __pyx_t_22 = 0; __pyx_t_23 = 0; __pyx_t_24 = 0; __pyx_t_25 = 0; __pyx_t_26 = 0; __pyx_t_27 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_19); __pyx_t_19 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_25, &__pyx_t_26, &__pyx_t_27); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_22, &__pyx_t_23, &__pyx_t_24) < 0)) __Pyx_ErrFetch(&__pyx_t_22, &__pyx_t_23, &__pyx_t_24); __Pyx_XGOTREF(__pyx_t_22); __Pyx_XGOTREF(__pyx_t_23); __Pyx_XGOTREF(__pyx_t_24); __Pyx_XGOTREF(__pyx_t_25); __Pyx_XGOTREF(__pyx_t_26); __Pyx_XGOTREF(__pyx_t_27); __pyx_t_14 = __pyx_lineno; __pyx_t_20 = __pyx_clineno; __pyx_t_21 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_25); __Pyx_XGIVEREF(__pyx_t_26); __Pyx_XGIVEREF(__pyx_t_27); __Pyx_ExceptionReset(__pyx_t_25, __pyx_t_26, __pyx_t_27); } __Pyx_XGIVEREF(__pyx_t_22); __Pyx_XGIVEREF(__pyx_t_23); __Pyx_XGIVEREF(__pyx_t_24); __Pyx_ErrRestore(__pyx_t_22, __pyx_t_23, __pyx_t_24); __pyx_t_22 = 0; __pyx_t_23 = 0; __pyx_t_24 = 0; __pyx_t_25 = 0; __pyx_t_26 = 0; __pyx_t_27 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_20; __pyx_filename = __pyx_t_21; goto __pyx_L52_except_error; } __pyx_L64:; } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; goto __pyx_L51_exception_handled; } goto __pyx_L52_except_error; __pyx_L52_except_error:; /* "src/handlers.pxi":579 * with lock: * if flags & XATTR_CREATE: # Attribute must not exist * try: # <<<<<<<<<<<<<< * operations.getxattr(ino, name) * except FUSEError as e: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); goto __pyx_L41_error; __pyx_L51_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); } /* "src/handlers.pxi":578 * * with lock: * if flags & XATTR_CREATE: # Attribute must not exist # <<<<<<<<<<<<<< * try: * operations.getxattr(ino, name) */ goto __pyx_L49; } /* "src/handlers.pxi":587 * raise FUSEError(errno.EEXIST) * * elif flags & XATTR_REPLACE: # Attribute must exist # <<<<<<<<<<<<<< * operations.getxattr(ino, name) * */ __pyx_t_6 = ((__pyx_v_flags & XATTR_REPLACE) != 0); if (__pyx_t_6) { /* "src/handlers.pxi":588 * * elif flags & XATTR_REPLACE: # Attribute must exist * operations.getxattr(ino, name) # <<<<<<<<<<<<<< * * operations.setxattr(ino, name, value, ctx) */ __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_getxattr); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_19 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_15))) { __pyx_t_19 = PyMethod_GET_SELF(__pyx_t_15); if (likely(__pyx_t_19)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_15); __Pyx_INCREF(__pyx_t_19); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_15, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[3] = {__pyx_t_19, __pyx_t_7, __pyx_v_name}; __pyx_t_10 = __Pyx_PyFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_XDECREF(__pyx_t_19); __pyx_t_19 = 0; __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[3] = {__pyx_t_19, __pyx_t_7, __pyx_v_name}; __pyx_t_10 = __Pyx_PyCFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_XDECREF(__pyx_t_19); __pyx_t_19 = 0; __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_19) { __Pyx_GIVEREF(__pyx_t_19); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_19); __pyx_t_19 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_20, __pyx_t_7); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_20, __pyx_v_name); __pyx_t_7 = 0; __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_15, __pyx_t_8, NULL); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 588, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; /* "src/handlers.pxi":587 * raise FUSEError(errno.EEXIST) * * elif flags & XATTR_REPLACE: # Attribute must exist # <<<<<<<<<<<<<< * operations.getxattr(ino, name) * */ } __pyx_L49:; /* "src/handlers.pxi":590 * operations.getxattr(ino, name) * * operations.setxattr(ino, name, value, ctx) # <<<<<<<<<<<<<< * * ret = fuse_reply_err(req, 0) */ __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_setxattr); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_8 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_7 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_15))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_15); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_15); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_15, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_t_8, __pyx_v_name, __pyx_v_value, __pyx_v_ctx}; __pyx_t_10 = __Pyx_PyFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_20, 4+__pyx_t_20); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_15)) { PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_t_8, __pyx_v_name, __pyx_v_value, __pyx_v_ctx}; __pyx_t_10 = __Pyx_PyCFunction_FastCall(__pyx_t_15, __pyx_temp+1-__pyx_t_20, 4+__pyx_t_20); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_19 = PyTuple_New(4+__pyx_t_20); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_19); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_19, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_19, 0+__pyx_t_20, __pyx_t_8); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_19, 1+__pyx_t_20, __pyx_v_name); __Pyx_INCREF(__pyx_v_value); __Pyx_GIVEREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_t_19, 2+__pyx_t_20, __pyx_v_value); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_19, 3+__pyx_t_20, __pyx_v_ctx); __pyx_t_8 = 0; __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_15, __pyx_t_19, NULL); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 590, __pyx_L41_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; /* "src/handlers.pxi":577 * raise ValueError('unknown flag(s): %o' % flags) * * with lock: # <<<<<<<<<<<<<< * if flags & XATTR_CREATE: # Attribute must not exist * try: */ } __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L48_try_end; __pyx_L41_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_19); __pyx_t_19 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_10, &__pyx_t_15, &__pyx_t_19) < 0) __PYX_ERR(1, 577, __pyx_L43_except_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_19); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_10, __pyx_t_15, __pyx_t_19); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 577, __pyx_L43_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_18 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_18)) __PYX_ERR(1, 577, __pyx_L43_except_error) __Pyx_GOTREF(__pyx_t_18); __pyx_t_6 = __Pyx_PyObject_IsTrue(__pyx_t_18); __Pyx_DECREF(__pyx_t_18); __pyx_t_18 = 0; if (__pyx_t_6 < 0) __PYX_ERR(1, 577, __pyx_L43_except_error) __pyx_t_5 = ((!(__pyx_t_6 != 0)) != 0); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_10); __Pyx_GIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ErrRestoreWithState(__pyx_t_10, __pyx_t_15, __pyx_t_19); __pyx_t_10 = 0; __pyx_t_15 = 0; __pyx_t_19 = 0; __PYX_ERR(1, 577, __pyx_L43_except_error) } __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; goto __pyx_L42_exception_handled; } __pyx_L43_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_13, __pyx_t_12, __pyx_t_11); goto __pyx_L3_error; __pyx_L42_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_13, __pyx_t_12, __pyx_t_11); __pyx_L48_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_9) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_tuple__33, NULL); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 577, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L40; } __pyx_L40:; } goto __pyx_L73; __pyx_L35_error:; __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; goto __pyx_L3_error; __pyx_L73:; } } __pyx_L15:; } __pyx_L12:; /* "src/handlers.pxi":592 * operations.setxattr(ino, name, value, ctx) * * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":557 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_19); __pyx_t_19 = 0; /* "src/handlers.pxi":593 * * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_20 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_20) { __Pyx_AddTraceback("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_19, &__pyx_t_15, &__pyx_t_10) < 0) __PYX_ERR(1, 593, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_19); __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_10); __Pyx_INCREF(__pyx_t_15); __Pyx_XDECREF_SET(__pyx_v_e, __pyx_t_15); /*try:*/ { /* "src/handlers.pxi":594 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 594, __pyx_L79_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_20 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_20 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 594, __pyx_L79_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_20); } /* "src/handlers.pxi":593 * * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L80; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L79_error:; __pyx_t_9 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_18 = 0; __pyx_t_17 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_13, &__pyx_t_18, &__pyx_t_17); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_9, &__pyx_t_11, &__pyx_t_12) < 0)) __Pyx_ErrFetch(&__pyx_t_9, &__pyx_t_11, &__pyx_t_12); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_18); __Pyx_XGOTREF(__pyx_t_17); __pyx_t_20 = __pyx_lineno; __pyx_t_14 = __pyx_clineno; __pyx_t_28 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_ExceptionReset(__pyx_t_13, __pyx_t_18, __pyx_t_17); } __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_ErrRestore(__pyx_t_9, __pyx_t_11, __pyx_t_12); __pyx_t_9 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_18 = 0; __pyx_t_17 = 0; __pyx_lineno = __pyx_t_20; __pyx_clineno = __pyx_t_14; __pyx_filename = __pyx_t_28; goto __pyx_L5_except_error; } __pyx_L80:; } __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":595 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_10, &__pyx_t_15, &__pyx_t_19) < 0) __PYX_ERR(1, 595, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_19); /* "src/handlers.pxi":596 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":557 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":598 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_5 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_5) { /* "src/handlers.pxi":599 * * if ret != 0: * log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_getxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, */ __pyx_t_15 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_15, __pyx_n_s_error); if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __pyx_t_15 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_8 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_10))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_10); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_10); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_10, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_setxattr_fuse_reply__failed, __pyx_t_15}; __pyx_t_19 = __Pyx_PyFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_19); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_10)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_setxattr_fuse_reply__failed, __pyx_t_15}; __pyx_t_19 = __Pyx_PyCFunction_FastCall(__pyx_t_10, __pyx_temp+1-__pyx_t_14, 2+__pyx_t_14); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_19); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_14); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_setxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_setxattr_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_14, __pyx_kp_u_fuse_setxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_15); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_14, __pyx_t_15); __pyx_t_15 = 0; __pyx_t_19 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_t_7, NULL); if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 599, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_19); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_19); __pyx_t_19 = 0; /* "src/handlers.pxi":598 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":553 * fuse_setxattr(req, ino, cname, cvalue, size, flags) * * cdef void fuse_setxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * const_char *cvalue, size_t size, int flags) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_10); __Pyx_XDECREF(__pyx_t_15); __Pyx_XDECREF(__pyx_t_19); __Pyx_WriteUnraisable("llfuse.fuse_setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_value); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":601 * log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_getxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * size_t size, uint32_t position) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_getxattr_darwin(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, const char *__pyx_v_cname, size_t __pyx_v_size, uint32_t __pyx_v_position) { int __pyx_v_ret; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_getxattr_darwin", 0); /* "src/handlers.pxi":605 * cdef int ret * * if position != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) * ret = fuse_reply_err(req, errno.EIO) */ __pyx_t_1 = ((__pyx_v_position != 0) != 0); if (__pyx_t_1) { /* "src/handlers.pxi":606 * * if position != 0: * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: */ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = __Pyx_PyInt_From_uint32_t(__pyx_v_position); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = PyUnicode_Format(__pyx_kp_u_fuse_getxattr_non_zero_position, __pyx_t_3); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (!__pyx_t_3) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_t_5}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[2] = {__pyx_t_3, __pyx_t_5}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif { __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_3); __pyx_t_3 = NULL; __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_t_5); __pyx_t_5 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_6, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 606, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/handlers.pxi":607 * if position != 0: * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) * ret = fuse_reply_err(req, errno.EIO) # <<<<<<<<<<<<<< * if ret != 0: * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, EIO); /* "src/handlers.pxi":608 * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * else: */ __pyx_t_1 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_1) { /* "src/handlers.pxi":609 * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * else: * fuse_getxattr(req, ino, cname, size) */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; __pyx_t_7 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_7 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_fuse_getxattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_fuse_getxattr_fuse_reply__failed, __pyx_t_4}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_3 = PyTuple_New(2+__pyx_t_7); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_getxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_getxattr_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_7, __pyx_kp_u_fuse_getxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_7, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 609, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/handlers.pxi":608 * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) * ret = fuse_reply_err(req, errno.EIO) * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * else: */ } /* "src/handlers.pxi":605 * cdef int ret * * if position != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): non-zero position (%d) not supported' % position) * ret = fuse_reply_err(req, errno.EIO) */ goto __pyx_L3; } /* "src/handlers.pxi":611 * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * else: * fuse_getxattr(req, ino, cname, size) # <<<<<<<<<<<<<< * * cdef void fuse_getxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, */ /*else*/ { __pyx_f_6llfuse_fuse_getxattr(__pyx_v_req, __pyx_v_ino, __pyx_v_cname, __pyx_v_size); } __pyx_L3:; /* "src/handlers.pxi":601 * log.error('fuse_setxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_getxattr_darwin (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * size_t size, uint32_t position) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_WriteUnraisable("llfuse.fuse_getxattr_darwin", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":613 * fuse_getxattr(req, ino, cname, size) * * cdef void fuse_getxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * size_t size) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_getxattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, const char *__pyx_v_cname, size_t __pyx_v_size) { int __pyx_v_ret; Py_ssize_t __pyx_v_len_s; size_t __pyx_v_len_; char *__pyx_v_cbuf; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_buf = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_getxattr", 0); /* "src/handlers.pxi":619 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":620 * cdef char *cbuf * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * name = PyBytes_FromString(cname) * with lock: */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 620, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":621 * try: * ctx = get_request_context(req) * name = PyBytes_FromString(cname) # <<<<<<<<<<<<<< * with lock: * buf = operations.getxattr(ino, name, ctx) */ __pyx_t_4 = PyBytes_FromString(__pyx_v_cname); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 621, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":622 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * buf = operations.getxattr(ino, name, ctx) * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 622, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 622, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 622, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 622, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 622, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":623 * name = PyBytes_FromString(cname) * with lock: * buf = operations.getxattr(ino, name, ctx) # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) * len_ = len_s # guaranteed positive */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_getxattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(3+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_name); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 2+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 623, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_buf = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":622 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * buf = operations.getxattr(ino, name, ctx) * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 622, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 622, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 622, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 622, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_13); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 622, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__34, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 622, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":624 * with lock: * buf = operations.getxattr(ino, name, ctx) * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) # <<<<<<<<<<<<<< * len_ = len_s # guaranteed positive * */ if (unlikely(!__pyx_v_buf)) { __Pyx_RaiseUnboundLocalError("buf"); __PYX_ERR(1, 624, __pyx_L3_error) } __pyx_t_12 = PyBytes_AsStringAndSize(__pyx_v_buf, (&__pyx_v_cbuf), ((Py_ssize_t *)(&__pyx_v_len_s))); if (unlikely(__pyx_t_12 == -1)) __PYX_ERR(1, 624, __pyx_L3_error) /* "src/handlers.pxi":625 * buf = operations.getxattr(ino, name, ctx) * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) * len_ = len_s # guaranteed positive # <<<<<<<<<<<<<< * * if size == 0: */ __pyx_v_len_ = ((size_t)__pyx_v_len_s); /* "src/handlers.pxi":627 * len_ = len_s # guaranteed positive * * if size == 0: # <<<<<<<<<<<<<< * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: */ __pyx_t_16 = ((__pyx_v_size == 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":628 * * if size == 0: * ret = fuse_reply_xattr(req, len_) # <<<<<<<<<<<<<< * elif len_ <= size: * ret = fuse_reply_buf(req, cbuf, len_) */ __pyx_v_ret = fuse_reply_xattr(__pyx_v_req, __pyx_v_len_); /* "src/handlers.pxi":627 * len_ = len_s # guaranteed positive * * if size == 0: # <<<<<<<<<<<<<< * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: */ goto __pyx_L29; } /* "src/handlers.pxi":629 * if size == 0: * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, cbuf, len_) * else: */ __pyx_t_16 = ((__pyx_v_len_ <= __pyx_v_size) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":630 * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: * ret = fuse_reply_buf(req, cbuf, len_) # <<<<<<<<<<<<<< * else: * ret = fuse_reply_err(req, errno.ERANGE) */ __pyx_v_ret = fuse_reply_buf(__pyx_v_req, __pyx_v_cbuf, __pyx_v_len_); /* "src/handlers.pxi":629 * if size == 0: * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, cbuf, len_) * else: */ goto __pyx_L29; } /* "src/handlers.pxi":632 * ret = fuse_reply_buf(req, cbuf, len_) * else: * ret = fuse_reply_err(req, errno.ERANGE) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ /*else*/ { __pyx_v_ret = fuse_reply_err(__pyx_v_req, ERANGE); } __pyx_L29:; /* "src/handlers.pxi":619 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":633 * else: * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 633, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":634 * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 634, __pyx_L35_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 634, __pyx_L35_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":633 * else: * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L36; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L35_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_12 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L36:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":635 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 635, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":636 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":619 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":638 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":639 * * if ret != 0: * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_listxattr (fuse_req_t req, fuse_ino_t ino, size_t size) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_getxattr_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_getxattr_fuse_reply__failed, __pyx_t_6}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_getxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_kp_u_fuse_getxattr_fuse_reply__failed); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_getxattr_fuse_reply__failed); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":638 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":613 * fuse_getxattr(req, ino, cname, size) * * cdef void fuse_getxattr (fuse_req_t req, fuse_ino_t ino, const_char *cname, # <<<<<<<<<<<<<< * size_t size) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_buf); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":641 * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_listxattr (fuse_req_t req, fuse_ino_t ino, size_t size) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef ssize_t len_s */ static void __pyx_f_6llfuse_fuse_listxattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, size_t __pyx_v_size) { int __pyx_v_ret; Py_ssize_t __pyx_v_len_s; size_t __pyx_v_len_; char *__pyx_v_cbuf; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_buf = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_listxattr", 0); /* "src/handlers.pxi":646 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":647 * cdef char *cbuf * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 647, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":648 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' * */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 648, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 648, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 648, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 648, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 648, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":649 * ctx = get_request_context(req) * with lock: * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' # <<<<<<<<<<<<<< * * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_listxattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_t_7, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 2+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(2+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __Pyx_PyBytes_Join(__pyx_kp_b__35, __pyx_t_4); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = PyNumber_Add(__pyx_t_6, __pyx_kp_b__35); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 649, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_buf = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":648 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' * */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 648, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 648, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 648, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 648, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_13); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 648, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__36, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 648, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":651 * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' * * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) # <<<<<<<<<<<<<< * len_ = len_s # guaranteed positive * */ if (unlikely(!__pyx_v_buf)) { __Pyx_RaiseUnboundLocalError("buf"); __PYX_ERR(1, 651, __pyx_L3_error) } __pyx_t_12 = PyBytes_AsStringAndSize(__pyx_v_buf, (&__pyx_v_cbuf), ((Py_ssize_t *)(&__pyx_v_len_s))); if (unlikely(__pyx_t_12 == -1)) __PYX_ERR(1, 651, __pyx_L3_error) /* "src/handlers.pxi":652 * * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) * len_ = len_s # guaranteed positive # <<<<<<<<<<<<<< * * if len_ == 1: # No attributes */ __pyx_v_len_ = ((size_t)__pyx_v_len_s); /* "src/handlers.pxi":654 * len_ = len_s # guaranteed positive * * if len_ == 1: # No attributes # <<<<<<<<<<<<<< * len_ = 0 * */ __pyx_t_16 = ((__pyx_v_len_ == 1) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":655 * * if len_ == 1: # No attributes * len_ = 0 # <<<<<<<<<<<<<< * * if size == 0: */ __pyx_v_len_ = 0; /* "src/handlers.pxi":654 * len_ = len_s # guaranteed positive * * if len_ == 1: # No attributes # <<<<<<<<<<<<<< * len_ = 0 * */ } /* "src/handlers.pxi":657 * len_ = 0 * * if size == 0: # <<<<<<<<<<<<<< * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: */ __pyx_t_16 = ((__pyx_v_size == 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":658 * * if size == 0: * ret = fuse_reply_xattr(req, len_) # <<<<<<<<<<<<<< * elif len_ <= size: * ret = fuse_reply_buf(req, cbuf, len_) */ __pyx_v_ret = fuse_reply_xattr(__pyx_v_req, __pyx_v_len_); /* "src/handlers.pxi":657 * len_ = 0 * * if size == 0: # <<<<<<<<<<<<<< * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: */ goto __pyx_L30; } /* "src/handlers.pxi":659 * if size == 0: * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, cbuf, len_) * else: */ __pyx_t_16 = ((__pyx_v_len_ <= __pyx_v_size) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":660 * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: * ret = fuse_reply_buf(req, cbuf, len_) # <<<<<<<<<<<<<< * else: * ret = fuse_reply_err(req, errno.ERANGE) */ __pyx_v_ret = fuse_reply_buf(__pyx_v_req, __pyx_v_cbuf, __pyx_v_len_); /* "src/handlers.pxi":659 * if size == 0: * ret = fuse_reply_xattr(req, len_) * elif len_ <= size: # <<<<<<<<<<<<<< * ret = fuse_reply_buf(req, cbuf, len_) * else: */ goto __pyx_L30; } /* "src/handlers.pxi":662 * ret = fuse_reply_buf(req, cbuf, len_) * else: * ret = fuse_reply_err(req, errno.ERANGE) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ /*else*/ { __pyx_v_ret = fuse_reply_err(__pyx_v_req, ERANGE); } __pyx_L30:; /* "src/handlers.pxi":646 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":663 * else: * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 663, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":664 * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 664, __pyx_L36_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 664, __pyx_L36_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":663 * else: * ret = fuse_reply_err(req, errno.ERANGE) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L37; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L36_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_12 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L37:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":665 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 665, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":666 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":646 * cdef size_t len_ * cdef char *cbuf * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":668 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":669 * * if ret != 0: * log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_listxattr_fuse_reply__faile, __pyx_t_6}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_listxattr_fuse_reply__faile, __pyx_t_6}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_listxattr_fuse_reply__faile); __Pyx_GIVEREF(__pyx_kp_u_fuse_listxattr_fuse_reply__faile); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_listxattr_fuse_reply__faile); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 669, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":668 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":641 * log.error('fuse_getxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_listxattr (fuse_req_t req, fuse_ino_t ino, size_t size) with gil: # <<<<<<<<<<<<<< * cdef int ret * cdef ssize_t len_s */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_listxattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_buf); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":671 * log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: # <<<<<<<<<<<<<< * cdef int ret * try: */ static void __pyx_f_6llfuse_fuse_removexattr(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, const char *__pyx_v_cname) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; int __pyx_t_15; int __pyx_t_16; int __pyx_t_17; char const *__pyx_t_18; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_removexattr", 0); /* "src/handlers.pxi":673 * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: * cdef int ret * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":674 * cdef int ret * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * name = PyBytes_FromString(cname) * with lock: */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 674, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":675 * try: * ctx = get_request_context(req) * name = PyBytes_FromString(cname) # <<<<<<<<<<<<<< * with lock: * operations.removexattr(ino, name, ctx) */ __pyx_t_4 = PyBytes_FromString(__pyx_v_cname); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 675, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":676 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 676, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 676, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 676, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 676, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 676, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":677 * name = PyBytes_FromString(cname) * with lock: * operations.removexattr(ino, name, ctx) # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * except FUSEError as e: */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_removexattr); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; __pyx_t_12 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_12 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_v_name, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_12, 3+__pyx_t_12); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else #endif { __pyx_t_13 = PyTuple_New(3+__pyx_t_12); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_13); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_13, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_13, 0+__pyx_t_12, __pyx_t_7); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_13, 1+__pyx_t_12, __pyx_v_name); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_13, 2+__pyx_t_12, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 677, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":676 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 676, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); __pyx_t_7 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_13); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 676, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 676, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_14); __pyx_t_15 = __Pyx_PyObject_IsTrue(__pyx_t_14); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; if (__pyx_t_15 < 0) __PYX_ERR(1, 676, __pyx_L19_except_error) __pyx_t_16 = ((!(__pyx_t_15 != 0)) != 0); if (__pyx_t_16) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_13); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_13 = 0; __PYX_ERR(1, 676, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__37, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 676, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":678 * with lock: * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":673 * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: * cdef int ret * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":679 * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_12 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_12) { __Pyx_AddTraceback("llfuse.fuse_removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_13, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 679, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":680 * ret = fuse_reply_err(req, 0) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 680, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_12 = __Pyx_PyInt_As_int(__pyx_t_7); if (unlikely((__pyx_t_12 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 680, __pyx_L34_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_12); } /* "src/handlers.pxi":679 * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_14, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_12 = __pyx_lineno; __pyx_t_17 = __pyx_clineno; __pyx_t_18 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_14, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_14 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_12; __pyx_clineno = __pyx_t_17; __pyx_filename = __pyx_t_18; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":681 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_13) < 0) __PYX_ERR(1, 681, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_13); /* "src/handlers.pxi":682 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":673 * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: * cdef int ret * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":684 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_16 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_16) { /* "src/handlers.pxi":685 * * if ret != 0: * log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * cdef void fuse_access (fuse_req_t req, fuse_ino_t ino, int mask) with gil: */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = NULL; __pyx_t_17 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_17 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_removexattr_fuse_reply__fai, __pyx_t_6}; __pyx_t_13 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_kp_u_fuse_removexattr_fuse_reply__fai, __pyx_t_6}; __pyx_t_13 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_17, 2+__pyx_t_17); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_17); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_7) { __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_removexattr_fuse_reply__fai); __Pyx_GIVEREF(__pyx_kp_u_fuse_removexattr_fuse_reply__fai); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_17, __pyx_kp_u_fuse_removexattr_fuse_reply__fai); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_17, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_13 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_8, NULL); if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 685, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_13); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_13); __pyx_t_13 = 0; /* "src/handlers.pxi":684 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":671 * log.error('fuse_listxattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_removexattr (fuse_req_t req, fuse_ino_t ino, const_char *cname) with gil: # <<<<<<<<<<<<<< * cdef int ret * try: */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_13); __Pyx_WriteUnraisable("llfuse.fuse_removexattr", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":687 * log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_access (fuse_req_t req, fuse_ino_t ino, int mask) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ static void __pyx_f_6llfuse_fuse_access(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_ino, int __pyx_v_mask) { int __pyx_v_ret; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_allowed = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; int __pyx_t_16; int __pyx_t_17; int __pyx_t_18; char const *__pyx_t_19; PyObject *__pyx_t_20 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_access", 0); /* "src/handlers.pxi":690 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":691 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * with lock: * allowed = operations.access(ino, mask, ctx) */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 691, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":692 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * allowed = operations.access(ino, mask, ctx) * if allowed: */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 692, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 692, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 692, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 692, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 692, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":693 * ctx = get_request_context(req) * with lock: * allowed = operations.access(ino, mask, ctx) # <<<<<<<<<<<<<< * if allowed: * ret = fuse_reply_err(req, 0) */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_access); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_ino); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_int(__pyx_v_mask); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = NULL; __pyx_t_13 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_13 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[4] = {__pyx_t_12, __pyx_t_7, __pyx_t_8, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_13, 3+__pyx_t_13); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_14 = PyTuple_New(3+__pyx_t_13); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_14); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_14, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_14, 0+__pyx_t_13, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_14, 1+__pyx_t_13, __pyx_t_8); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_14, 2+__pyx_t_13, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 693, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_allowed = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":692 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * allowed = operations.access(ino, mask, ctx) * if allowed: */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_access", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 692, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); __pyx_t_8 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_6, __pyx_t_14); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 692, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_8, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 692, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_15); __pyx_t_16 = __Pyx_PyObject_IsTrue(__pyx_t_15); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; if (__pyx_t_16 < 0) __PYX_ERR(1, 692, __pyx_L19_except_error) __pyx_t_17 = ((!(__pyx_t_16 != 0)) != 0); if (__pyx_t_17) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_6, __pyx_t_14); __pyx_t_4 = 0; __pyx_t_6 = 0; __pyx_t_14 = 0; __PYX_ERR(1, 692, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__38, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 692, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":694 * with lock: * allowed = operations.access(ino, mask, ctx) * if allowed: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * else: */ if (unlikely(!__pyx_v_allowed)) { __Pyx_RaiseUnboundLocalError("allowed"); __PYX_ERR(1, 694, __pyx_L3_error) } __pyx_t_17 = __Pyx_PyObject_IsTrue(__pyx_v_allowed); if (unlikely(__pyx_t_17 < 0)) __PYX_ERR(1, 694, __pyx_L3_error) if (__pyx_t_17) { /* "src/handlers.pxi":695 * allowed = operations.access(ino, mask, ctx) * if allowed: * ret = fuse_reply_err(req, 0) # <<<<<<<<<<<<<< * else: * ret = fuse_reply_err(req, EPERM) */ __pyx_v_ret = fuse_reply_err(__pyx_v_req, 0); /* "src/handlers.pxi":694 * with lock: * allowed = operations.access(ino, mask, ctx) * if allowed: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, 0) * else: */ goto __pyx_L29; } /* "src/handlers.pxi":697 * ret = fuse_reply_err(req, 0) * else: * ret = fuse_reply_err(req, EPERM) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ /*else*/ { __pyx_v_ret = fuse_reply_err(__pyx_v_req, EPERM); } __pyx_L29:; /* "src/handlers.pxi":690 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":698 * else: * ret = fuse_reply_err(req, EPERM) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_13 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_13) { __Pyx_AddTraceback("llfuse.fuse_access", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_14, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(1, 698, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_INCREF(__pyx_t_6); __pyx_v_e = __pyx_t_6; /*try:*/ { /* "src/handlers.pxi":699 * ret = fuse_reply_err(req, EPERM) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 699, __pyx_L35_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_13 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_13 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 699, __pyx_L35_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_13); } /* "src/handlers.pxi":698 * else: * ret = fuse_reply_err(req, EPERM) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L36; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L35_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_15, &__pyx_t_20); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_20); __pyx_t_13 = __pyx_lineno; __pyx_t_18 = __pyx_clineno; __pyx_t_19 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_20); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_15, __pyx_t_20); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_15 = 0; __pyx_t_20 = 0; __pyx_lineno = __pyx_t_13; __pyx_clineno = __pyx_t_18; __pyx_filename = __pyx_t_19; goto __pyx_L5_except_error; } __pyx_L36:; } __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":700 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_access", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_14) < 0) __PYX_ERR(1, 700, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_14); /* "src/handlers.pxi":701 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":690 * cdef int ret * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * with lock: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":703 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_access(): fuse_reply_* failed with %s', strerror(-ret)) * */ __pyx_t_17 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_17) { /* "src/handlers.pxi":704 * * if ret != 0: * log.error('fuse_access(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< * * */ __pyx_t_6 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_6 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_8 = NULL; __pyx_t_18 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_18 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_access_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_14 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_fuse_access_fuse_reply__failed_w, __pyx_t_6}; __pyx_t_14 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_18, 2+__pyx_t_18); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_18); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_access_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_access_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_18, __pyx_kp_u_fuse_access_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_18, __pyx_t_6); __pyx_t_6 = 0; __pyx_t_14 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 704, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_14); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_14); __pyx_t_14 = 0; /* "src/handlers.pxi":703 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_access(): fuse_reply_* failed with %s', strerror(-ret)) * */ } /* "src/handlers.pxi":687 * log.error('fuse_removexattr(): fuse_reply_* failed with %s', strerror(-ret)) * * cdef void fuse_access (fuse_req_t req, fuse_ino_t ino, int mask) with gil: # <<<<<<<<<<<<<< * cdef int ret * */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_14); __Pyx_WriteUnraisable("llfuse.fuse_access", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_allowed); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/handlers.pxi":707 * * * cdef void fuse_create (fuse_req_t req, fuse_ino_t parent, const_char *cname, # <<<<<<<<<<<<<< * mode_t mode, fuse_file_info *fi) with gil: * cdef int ret */ static void __pyx_f_6llfuse_fuse_create(fuse_req_t __pyx_v_req, fuse_ino_t __pyx_v_parent, const char *__pyx_v_cname, mode_t __pyx_v_mode, struct fuse_file_info *__pyx_v_fi) { int __pyx_v_ret; struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_entry = 0; PyObject *__pyx_v_ctx = NULL; PyObject *__pyx_v_name = NULL; PyObject *__pyx_v_tmp = NULL; PyObject *__pyx_v_e = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; int __pyx_t_14; PyObject *__pyx_t_15 = NULL; uint64_t __pyx_t_16; PyObject *__pyx_t_17 = NULL; int __pyx_t_18; int __pyx_t_19; int __pyx_t_20; char const *__pyx_t_21; PyObject *__pyx_t_22 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("fuse_create", 0); /* "src/handlers.pxi":712 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/handlers.pxi":713 * * try: * ctx = get_request_context(req) # <<<<<<<<<<<<<< * name = PyBytes_FromString(cname) * with lock: */ __pyx_t_4 = __pyx_f_6llfuse_get_request_context(__pyx_v_req); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 713, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_ctx = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":714 * try: * ctx = get_request_context(req) * name = PyBytes_FromString(cname) # <<<<<<<<<<<<<< * with lock: * tmp = operations.create(parent, name, mode, fi.flags, ctx) */ __pyx_t_4 = PyBytes_FromString(__pyx_v_cname); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 714, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_v_name = ((PyObject*)__pyx_t_4); __pyx_t_4 = 0; /* "src/handlers.pxi":715 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * tmp = operations.create(parent, name, mode, fi.flags, ctx) * fi.fh = tmp[0] */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 715, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_exit); if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 715, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = __Pyx_PyObject_LookupSpecial(__pyx_t_4, __pyx_n_s_enter); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 715, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_8) { __pyx_t_6 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_8); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 715, __pyx_L11_error) __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else { __pyx_t_6 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 715, __pyx_L11_error) } __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/handlers.pxi":716 * name = PyBytes_FromString(cname) * with lock: * tmp = operations.create(parent, name, mode, fi.flags, ctx) # <<<<<<<<<<<<<< * fi.fh = tmp[0] * entry = tmp[1] */ __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse_operations, __pyx_n_s_create); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_7 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_parent); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __Pyx_PyInt_From_mode_t(__pyx_v_mode); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_12 = __Pyx_PyInt_From_int(__pyx_v_fi->flags); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_13 = NULL; __pyx_t_14 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) { __pyx_t_13 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_13)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_13); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_14 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_13, __pyx_t_7, __pyx_v_name, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 5+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[6] = {__pyx_t_13, __pyx_t_7, __pyx_v_name, __pyx_t_8, __pyx_t_12, __pyx_v_ctx}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_14, 5+__pyx_t_14); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else #endif { __pyx_t_15 = PyTuple_New(5+__pyx_t_14); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_15); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_13); PyTuple_SET_ITEM(__pyx_t_15, 0, __pyx_t_13); __pyx_t_13 = NULL; } __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_15, 0+__pyx_t_14, __pyx_t_7); __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); PyTuple_SET_ITEM(__pyx_t_15, 1+__pyx_t_14, __pyx_v_name); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_15, 2+__pyx_t_14, __pyx_t_8); __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_15, 3+__pyx_t_14, __pyx_t_12); __Pyx_INCREF(__pyx_v_ctx); __Pyx_GIVEREF(__pyx_v_ctx); PyTuple_SET_ITEM(__pyx_t_15, 4+__pyx_t_14, __pyx_v_ctx); __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_12 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_15, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 716, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_v_tmp = __pyx_t_4; __pyx_t_4 = 0; /* "src/handlers.pxi":717 * with lock: * tmp = operations.create(parent, name, mode, fi.flags, ctx) * fi.fh = tmp[0] # <<<<<<<<<<<<<< * entry = tmp[1] * */ __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_tmp, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 717, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_16 = __Pyx_PyInt_As_uint64_t(__pyx_t_4); if (unlikely((__pyx_t_16 == ((uint64_t)-1)) && PyErr_Occurred())) __PYX_ERR(1, 717, __pyx_L17_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_fi->fh = __pyx_t_16; /* "src/handlers.pxi":718 * tmp = operations.create(parent, name, mode, fi.flags, ctx) * fi.fh = tmp[0] * entry = tmp[1] # <<<<<<<<<<<<<< * * # Cached file data does not need to be invalidated. */ __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_tmp, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 718, __pyx_L17_error) __Pyx_GOTREF(__pyx_t_4); if (!(likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_6llfuse_EntryAttributes)))) __PYX_ERR(1, 718, __pyx_L17_error) __pyx_t_6 = __pyx_t_4; __Pyx_INCREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_entry = ((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_t_6); __pyx_t_6 = 0; /* "src/handlers.pxi":715 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * tmp = operations.create(parent, name, mode, fi.flags, ctx) * fi.fh = tmp[0] */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L24_try_end; __pyx_L17_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_create", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 715, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); __pyx_t_12 = PyTuple_Pack(3, __pyx_t_6, __pyx_t_4, __pyx_t_15); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 715, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_17 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_12, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 715, __pyx_L19_except_error) __Pyx_GOTREF(__pyx_t_17); __pyx_t_18 = __Pyx_PyObject_IsTrue(__pyx_t_17); __Pyx_DECREF(__pyx_t_17); __pyx_t_17 = 0; if (__pyx_t_18 < 0) __PYX_ERR(1, 715, __pyx_L19_except_error) __pyx_t_19 = ((!(__pyx_t_18 != 0)) != 0); if (__pyx_t_19) { __Pyx_GIVEREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestoreWithState(__pyx_t_6, __pyx_t_4, __pyx_t_15); __pyx_t_6 = 0; __pyx_t_4 = 0; __pyx_t_15 = 0; __PYX_ERR(1, 715, __pyx_L19_except_error) } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L18_exception_handled; } __pyx_L19_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L3_error; __pyx_L18_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); __pyx_L24_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_5) { __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_tuple__39, NULL); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 715, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } goto __pyx_L16; } __pyx_L16:; } goto __pyx_L28; __pyx_L11_error:; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; goto __pyx_L3_error; __pyx_L28:; } /* "src/handlers.pxi":722 * # Cached file data does not need to be invalidated. * # http://article.gmane.org/gmane.comp.file-systems.fuse.devel/5325/ * fi.keep_cache = 1 # <<<<<<<<<<<<<< * * ret = fuse_reply_create(req, &entry.fuse_param, fi) */ __pyx_v_fi->keep_cache = 1; /* "src/handlers.pxi":724 * fi.keep_cache = 1 * * ret = fuse_reply_create(req, &entry.fuse_param, fi) # <<<<<<<<<<<<<< * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) */ if (unlikely(!__pyx_v_entry)) { __Pyx_RaiseUnboundLocalError("entry"); __PYX_ERR(1, 724, __pyx_L3_error) } __pyx_v_ret = fuse_reply_create(__pyx_v_req, (&__pyx_v_entry->fuse_param), __pyx_v_fi); /* "src/handlers.pxi":712 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ } __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L10_try_end; __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":725 * * ret = fuse_reply_create(req, &entry.fuse_param, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ __pyx_t_14 = __Pyx_PyErr_ExceptionMatches(((PyObject *)__pyx_ptype_6llfuse_FUSEError)); if (__pyx_t_14) { __Pyx_AddTraceback("llfuse.fuse_create", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_15, &__pyx_t_4, &__pyx_t_6) < 0) __PYX_ERR(1, 725, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_INCREF(__pyx_t_4); __pyx_v_e = __pyx_t_4; /*try:*/ { /* "src/handlers.pxi":726 * ret = fuse_reply_create(req, &entry.fuse_param, fi) * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) # <<<<<<<<<<<<<< * except: * ret = handle_exc(req) */ __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_e, __pyx_n_s_errno); if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 726, __pyx_L34_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_14 = __Pyx_PyInt_As_int(__pyx_t_12); if (unlikely((__pyx_t_14 == (int)-1) && PyErr_Occurred())) __PYX_ERR(1, 726, __pyx_L34_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_v_ret = fuse_reply_err(__pyx_v_req, __pyx_t_14); } /* "src/handlers.pxi":725 * * ret = fuse_reply_create(req, &entry.fuse_param, fi) * except FUSEError as e: # <<<<<<<<<<<<<< * ret = fuse_reply_err(req, e.errno) * except: */ /*finally:*/ { /*normal exit:*/{ __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; goto __pyx_L35; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L34_error:; __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_17, &__pyx_t_22); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10) < 0)) __Pyx_ErrFetch(&__pyx_t_5, &__pyx_t_11, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_22); __pyx_t_14 = __pyx_lineno; __pyx_t_20 = __pyx_clineno; __pyx_t_21 = __pyx_filename; { __Pyx_DECREF(__pyx_v_e); __pyx_v_e = NULL; } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_22); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_17, __pyx_t_22); } __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ErrRestore(__pyx_t_5, __pyx_t_11, __pyx_t_10); __pyx_t_5 = 0; __pyx_t_11 = 0; __pyx_t_10 = 0; __pyx_t_9 = 0; __pyx_t_17 = 0; __pyx_t_22 = 0; __pyx_lineno = __pyx_t_14; __pyx_clineno = __pyx_t_20; __pyx_filename = __pyx_t_21; goto __pyx_L5_except_error; } __pyx_L35:; } __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L4_exception_handled; } /* "src/handlers.pxi":727 * except FUSEError as e: * ret = fuse_reply_err(req, e.errno) * except: # <<<<<<<<<<<<<< * ret = handle_exc(req) * */ /*except:*/ { __Pyx_AddTraceback("llfuse.fuse_create", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_6, &__pyx_t_4, &__pyx_t_15) < 0) __PYX_ERR(1, 727, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_15); /* "src/handlers.pxi":728 * ret = fuse_reply_err(req, e.errno) * except: * ret = handle_exc(req) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = __pyx_f_6llfuse_handle_exc(__pyx_v_req); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; goto __pyx_L4_exception_handled; } __pyx_L5_except_error:; /* "src/handlers.pxi":712 * cdef EntryAttributes entry * * try: # <<<<<<<<<<<<<< * ctx = get_request_context(req) * name = PyBytes_FromString(cname) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L4_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); __pyx_L10_try_end:; } /* "src/handlers.pxi":730 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_create(): fuse_reply_* failed with %s', strerror(-ret)) */ __pyx_t_19 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_19) { /* "src/handlers.pxi":731 * * if ret != 0: * log.error('fuse_create(): fuse_reply_* failed with %s', strerror(-ret)) # <<<<<<<<<<<<<< */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_12 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_create_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_15 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[3] = {__pyx_t_12, __pyx_kp_u_fuse_create_fuse_reply__failed_w, __pyx_t_4}; __pyx_t_15 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_12) { __Pyx_GIVEREF(__pyx_t_12); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_12); __pyx_t_12 = NULL; } __Pyx_INCREF(__pyx_kp_u_fuse_create_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_kp_u_fuse_create_fuse_reply__failed_w); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_20, __pyx_kp_u_fuse_create_fuse_reply__failed_w); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_20, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_15 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 731, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_15); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_15); __pyx_t_15 = 0; /* "src/handlers.pxi":730 * ret = handle_exc(req) * * if ret != 0: # <<<<<<<<<<<<<< * log.error('fuse_create(): fuse_reply_* failed with %s', strerror(-ret)) */ } /* "src/handlers.pxi":707 * * * cdef void fuse_create (fuse_req_t req, fuse_ino_t parent, const_char *cname, # <<<<<<<<<<<<<< * mode_t mode, fuse_file_info *fi) with gil: * cdef int ret */ /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_12); __Pyx_XDECREF(__pyx_t_13); __Pyx_XDECREF(__pyx_t_15); __Pyx_WriteUnraisable("llfuse.fuse_create", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_entry); __Pyx_XDECREF(__pyx_v_ctx); __Pyx_XDECREF(__pyx_v_name); __Pyx_XDECREF(__pyx_v_tmp); __Pyx_XDECREF(__pyx_v_e); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif } /* "src/misc.pxi":13 * ''' * * cdef int handle_exc(fuse_req_t req): # <<<<<<<<<<<<<< * '''Try to call fuse_reply_err and terminate main loop''' * */ static int __pyx_f_6llfuse_handle_exc(fuse_req_t __pyx_v_req) { int __pyx_v_res; int __pyx_r; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; int __pyx_t_8; PyObject *__pyx_t_9 = NULL; __Pyx_RefNannySetupContext("handle_exc", 0); /* "src/misc.pxi":19 * global exc_info * * res = pthread_mutex_lock(&exc_info_mutex) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_mutex_lock failed with %s', */ __pyx_v_res = pthread_mutex_lock((&__pyx_v_6llfuse_exc_info_mutex)); /* "src/misc.pxi":20 * * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_lock failed with %s', * strerror(res)) */ __pyx_t_1 = ((__pyx_v_res != 0) != 0); if (__pyx_t_1) { /* "src/misc.pxi":21 * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: * log.error('pthread_mutex_lock failed with %s', # <<<<<<<<<<<<<< * strerror(res)) * if not exc_info: */ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/misc.pxi":22 * if res != 0: * log.error('pthread_mutex_lock failed with %s', * strerror(res)) # <<<<<<<<<<<<<< * if not exc_info: * exc_info = sys.exc_info() */ __pyx_t_3 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 22, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_pthread_mutex_lock_failed_with_s, __pyx_t_3}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_kp_u_pthread_mutex_lock_failed_with_s, __pyx_t_3}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_mutex_lock_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_mutex_lock_failed_with_s); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_kp_u_pthread_mutex_lock_failed_with_s); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_t_3); __pyx_t_3 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 21, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/misc.pxi":20 * * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_lock failed with %s', * strerror(res)) */ } /* "src/misc.pxi":23 * log.error('pthread_mutex_lock failed with %s', * strerror(res)) * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * log.info('handler raised %s exception (%s), terminating main loop.', */ __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_6llfuse_exc_info); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(2, 23, __pyx_L1_error) __pyx_t_8 = ((!__pyx_t_1) != 0); if (__pyx_t_8) { /* "src/misc.pxi":24 * strerror(res)) * if not exc_info: * exc_info = sys.exc_info() # <<<<<<<<<<<<<< * log.info('handler raised %s exception (%s), terminating main loop.', * exc_info[0], exc_info[1]) */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_sys); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 24, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_exc_info); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 24, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (__pyx_t_4) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 24, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 24, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/misc.pxi":25 * if not exc_info: * exc_info = sys.exc_info() * log.info('handler raised %s exception (%s), terminating main loop.', # <<<<<<<<<<<<<< * exc_info[0], exc_info[1]) * fuse_session_exit(session) */ __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_info); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/misc.pxi":26 * exc_info = sys.exc_info() * log.info('handler raised %s exception (%s), terminating main loop.', * exc_info[0], exc_info[1]) # <<<<<<<<<<<<<< * fuse_session_exit(session) * else: */ __pyx_t_7 = __Pyx_GetItemInt(__pyx_v_6llfuse_exc_info, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 26, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_3 = __Pyx_GetItemInt(__pyx_v_6llfuse_exc_info, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 26, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_5 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[4] = {__pyx_t_5, __pyx_kp_u_handler_raised_s_exception_s_ter, __pyx_t_7, __pyx_t_3}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[4] = {__pyx_t_5, __pyx_kp_u_handler_raised_s_exception_s_ter, __pyx_t_7, __pyx_t_3}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { __pyx_t_9 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_9)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_INCREF(__pyx_kp_u_handler_raised_s_exception_s_ter); __Pyx_GIVEREF(__pyx_kp_u_handler_raised_s_exception_s_ter); PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_6, __pyx_kp_u_handler_raised_s_exception_s_ter); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_6, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_6, __pyx_t_3); __pyx_t_7 = 0; __pyx_t_3 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 25, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/misc.pxi":27 * log.info('handler raised %s exception (%s), terminating main loop.', * exc_info[0], exc_info[1]) * fuse_session_exit(session) # <<<<<<<<<<<<<< * else: * log.exception('Only one exception can be re-raised in `llfuse.main`, ' */ fuse_session_exit(__pyx_v_6llfuse_session); /* "src/misc.pxi":23 * log.error('pthread_mutex_lock failed with %s', * strerror(res)) * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * log.info('handler raised %s exception (%s), terminating main loop.', */ goto __pyx_L4; } /* "src/misc.pxi":29 * fuse_session_exit(session) * else: * log.exception('Only one exception can be re-raised in `llfuse.main`, ' # <<<<<<<<<<<<<< * 'the following exception will be lost') * */ /*else*/ { __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 29, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_exception); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 29, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__40, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 29, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } __pyx_L4:; /* "src/misc.pxi":32 * 'the following exception will be lost') * * pthread_mutex_unlock(&exc_info_mutex) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_mutex_ulock failed with %s', */ pthread_mutex_unlock((&__pyx_v_6llfuse_exc_info_mutex)); /* "src/misc.pxi":33 * * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) */ __pyx_t_8 = ((__pyx_v_res != 0) != 0); if (__pyx_t_8) { /* "src/misc.pxi":34 * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: * log.error('pthread_mutex_ulock failed with %s', # <<<<<<<<<<<<<< * strerror(res)) * */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_9)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/misc.pxi":35 * if res != 0: * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) # <<<<<<<<<<<<<< * * if req is NULL: */ __pyx_t_4 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 35, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_9))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_9); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_9, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_pthread_mutex_ulock_failed_with, __pyx_t_4}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_pthread_mutex_ulock_failed_with, __pyx_t_4}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_3); __pyx_t_3 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_mutex_ulock_failed_with); __Pyx_GIVEREF(__pyx_kp_u_pthread_mutex_ulock_failed_with); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_kp_u_pthread_mutex_ulock_failed_with); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 34, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/misc.pxi":33 * * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) */ } /* "src/misc.pxi":37 * strerror(res)) * * if req is NULL: # <<<<<<<<<<<<<< * return 0 * else: */ __pyx_t_8 = ((__pyx_v_req == NULL) != 0); if (__pyx_t_8) { /* "src/misc.pxi":38 * * if req is NULL: * return 0 # <<<<<<<<<<<<<< * else: * return fuse_reply_err(req, errno.EIO) */ __pyx_r = 0; goto __pyx_L0; /* "src/misc.pxi":37 * strerror(res)) * * if req is NULL: # <<<<<<<<<<<<<< * return 0 * else: */ } /* "src/misc.pxi":40 * return 0 * else: * return fuse_reply_err(req, errno.EIO) # <<<<<<<<<<<<<< * * cdef object get_request_context(fuse_req_t req): */ /*else*/ { __pyx_r = fuse_reply_err(__pyx_v_req, EIO); goto __pyx_L0; } /* "src/misc.pxi":13 * ''' * * cdef int handle_exc(fuse_req_t req): # <<<<<<<<<<<<<< * '''Try to call fuse_reply_err and terminate main loop''' * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_9); __Pyx_WriteUnraisable("llfuse.handle_exc", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_r = 0; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":42 * return fuse_reply_err(req, errno.EIO) * * cdef object get_request_context(fuse_req_t req): # <<<<<<<<<<<<<< * '''Get RequestContext() object''' * */ static PyObject *__pyx_f_6llfuse_get_request_context(fuse_req_t __pyx_v_req) { const struct fuse_ctx *__pyx_v_context; struct __pyx_obj_6llfuse_RequestContext *__pyx_v_ctx = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; pid_t __pyx_t_2; uid_t __pyx_t_3; gid_t __pyx_t_4; mode_t __pyx_t_5; __Pyx_RefNannySetupContext("get_request_context", 0); /* "src/misc.pxi":48 * cdef RequestContext ctx * * context = fuse_req_ctx(req) # <<<<<<<<<<<<<< * ctx = RequestContext.__new__(RequestContext) * ctx.pid = context.pid */ __pyx_v_context = fuse_req_ctx(__pyx_v_req); /* "src/misc.pxi":49 * * context = fuse_req_ctx(req) * ctx = RequestContext.__new__(RequestContext) # <<<<<<<<<<<<<< * ctx.pid = context.pid * ctx.uid = context.uid */ __pyx_t_1 = __pyx_tp_new_6llfuse_RequestContext(((PyTypeObject *)__pyx_ptype_6llfuse_RequestContext), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 49, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_6llfuse_RequestContext)))) __PYX_ERR(2, 49, __pyx_L1_error) __pyx_v_ctx = ((struct __pyx_obj_6llfuse_RequestContext *)__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":50 * context = fuse_req_ctx(req) * ctx = RequestContext.__new__(RequestContext) * ctx.pid = context.pid # <<<<<<<<<<<<<< * ctx.uid = context.uid * ctx.gid = context.gid */ __pyx_t_2 = __pyx_v_context->pid; __pyx_v_ctx->pid = __pyx_t_2; /* "src/misc.pxi":51 * ctx = RequestContext.__new__(RequestContext) * ctx.pid = context.pid * ctx.uid = context.uid # <<<<<<<<<<<<<< * ctx.gid = context.gid * ctx.umask = context.umask */ __pyx_t_3 = __pyx_v_context->uid; __pyx_v_ctx->uid = __pyx_t_3; /* "src/misc.pxi":52 * ctx.pid = context.pid * ctx.uid = context.uid * ctx.gid = context.gid # <<<<<<<<<<<<<< * ctx.umask = context.umask * */ __pyx_t_4 = __pyx_v_context->gid; __pyx_v_ctx->gid = __pyx_t_4; /* "src/misc.pxi":53 * ctx.uid = context.uid * ctx.gid = context.gid * ctx.umask = context.umask # <<<<<<<<<<<<<< * * return ctx */ __pyx_t_5 = __pyx_v_context->umask; __pyx_v_ctx->umask = __pyx_t_5; /* "src/misc.pxi":55 * ctx.umask = context.umask * * return ctx # <<<<<<<<<<<<<< * * cdef void init_fuse_ops(): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(((PyObject *)__pyx_v_ctx)); __pyx_r = ((PyObject *)__pyx_v_ctx); goto __pyx_L0; /* "src/misc.pxi":42 * return fuse_reply_err(req, errno.EIO) * * cdef object get_request_context(fuse_req_t req): # <<<<<<<<<<<<<< * '''Get RequestContext() object''' * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.get_request_context", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_ctx); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":57 * return ctx * * cdef void init_fuse_ops(): # <<<<<<<<<<<<<< * '''Initialize fuse_lowlevel_ops structure''' * */ static void __pyx_f_6llfuse_init_fuse_ops(void) { __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("init_fuse_ops", 0); /* "src/misc.pxi":60 * '''Initialize fuse_lowlevel_ops structure''' * * string.memset(&fuse_ops, 0, sizeof(fuse_lowlevel_ops)) # <<<<<<<<<<<<<< * * fuse_ops.init = fuse_init */ memset((&__pyx_v_6llfuse_fuse_ops), 0, (sizeof(struct fuse_lowlevel_ops))); /* "src/misc.pxi":62 * string.memset(&fuse_ops, 0, sizeof(fuse_lowlevel_ops)) * * fuse_ops.init = fuse_init # <<<<<<<<<<<<<< * fuse_ops.destroy = fuse_destroy * fuse_ops.lookup = fuse_lookup */ __pyx_v_6llfuse_fuse_ops.init = __pyx_f_6llfuse_fuse_init; /* "src/misc.pxi":63 * * fuse_ops.init = fuse_init * fuse_ops.destroy = fuse_destroy # <<<<<<<<<<<<<< * fuse_ops.lookup = fuse_lookup * fuse_ops.forget = fuse_forget */ __pyx_v_6llfuse_fuse_ops.destroy = __pyx_f_6llfuse_fuse_destroy; /* "src/misc.pxi":64 * fuse_ops.init = fuse_init * fuse_ops.destroy = fuse_destroy * fuse_ops.lookup = fuse_lookup # <<<<<<<<<<<<<< * fuse_ops.forget = fuse_forget * fuse_ops.getattr = fuse_getattr */ __pyx_v_6llfuse_fuse_ops.lookup = __pyx_f_6llfuse_fuse_lookup; /* "src/misc.pxi":65 * fuse_ops.destroy = fuse_destroy * fuse_ops.lookup = fuse_lookup * fuse_ops.forget = fuse_forget # <<<<<<<<<<<<<< * fuse_ops.getattr = fuse_getattr * fuse_ops.setattr = fuse_setattr */ __pyx_v_6llfuse_fuse_ops.forget = __pyx_f_6llfuse_fuse_forget; /* "src/misc.pxi":66 * fuse_ops.lookup = fuse_lookup * fuse_ops.forget = fuse_forget * fuse_ops.getattr = fuse_getattr # <<<<<<<<<<<<<< * fuse_ops.setattr = fuse_setattr * fuse_ops.readlink = fuse_readlink */ __pyx_v_6llfuse_fuse_ops.getattr = __pyx_f_6llfuse_fuse_getattr; /* "src/misc.pxi":67 * fuse_ops.forget = fuse_forget * fuse_ops.getattr = fuse_getattr * fuse_ops.setattr = fuse_setattr # <<<<<<<<<<<<<< * fuse_ops.readlink = fuse_readlink * fuse_ops.mknod = fuse_mknod */ __pyx_v_6llfuse_fuse_ops.setattr = __pyx_f_6llfuse_fuse_setattr; /* "src/misc.pxi":68 * fuse_ops.getattr = fuse_getattr * fuse_ops.setattr = fuse_setattr * fuse_ops.readlink = fuse_readlink # <<<<<<<<<<<<<< * fuse_ops.mknod = fuse_mknod * fuse_ops.mkdir = fuse_mkdir */ __pyx_v_6llfuse_fuse_ops.readlink = __pyx_f_6llfuse_fuse_readlink; /* "src/misc.pxi":69 * fuse_ops.setattr = fuse_setattr * fuse_ops.readlink = fuse_readlink * fuse_ops.mknod = fuse_mknod # <<<<<<<<<<<<<< * fuse_ops.mkdir = fuse_mkdir * fuse_ops.unlink = fuse_unlink */ __pyx_v_6llfuse_fuse_ops.mknod = __pyx_f_6llfuse_fuse_mknod; /* "src/misc.pxi":70 * fuse_ops.readlink = fuse_readlink * fuse_ops.mknod = fuse_mknod * fuse_ops.mkdir = fuse_mkdir # <<<<<<<<<<<<<< * fuse_ops.unlink = fuse_unlink * fuse_ops.rmdir = fuse_rmdir */ __pyx_v_6llfuse_fuse_ops.mkdir = __pyx_f_6llfuse_fuse_mkdir; /* "src/misc.pxi":71 * fuse_ops.mknod = fuse_mknod * fuse_ops.mkdir = fuse_mkdir * fuse_ops.unlink = fuse_unlink # <<<<<<<<<<<<<< * fuse_ops.rmdir = fuse_rmdir * fuse_ops.symlink = fuse_symlink */ __pyx_v_6llfuse_fuse_ops.unlink = __pyx_f_6llfuse_fuse_unlink; /* "src/misc.pxi":72 * fuse_ops.mkdir = fuse_mkdir * fuse_ops.unlink = fuse_unlink * fuse_ops.rmdir = fuse_rmdir # <<<<<<<<<<<<<< * fuse_ops.symlink = fuse_symlink * fuse_ops.rename = fuse_rename */ __pyx_v_6llfuse_fuse_ops.rmdir = __pyx_f_6llfuse_fuse_rmdir; /* "src/misc.pxi":73 * fuse_ops.unlink = fuse_unlink * fuse_ops.rmdir = fuse_rmdir * fuse_ops.symlink = fuse_symlink # <<<<<<<<<<<<<< * fuse_ops.rename = fuse_rename * fuse_ops.link = fuse_link */ __pyx_v_6llfuse_fuse_ops.symlink = __pyx_f_6llfuse_fuse_symlink; /* "src/misc.pxi":74 * fuse_ops.rmdir = fuse_rmdir * fuse_ops.symlink = fuse_symlink * fuse_ops.rename = fuse_rename # <<<<<<<<<<<<<< * fuse_ops.link = fuse_link * fuse_ops.open = fuse_open */ __pyx_v_6llfuse_fuse_ops.rename = __pyx_f_6llfuse_fuse_rename; /* "src/misc.pxi":75 * fuse_ops.symlink = fuse_symlink * fuse_ops.rename = fuse_rename * fuse_ops.link = fuse_link # <<<<<<<<<<<<<< * fuse_ops.open = fuse_open * fuse_ops.read = fuse_read */ __pyx_v_6llfuse_fuse_ops.link = __pyx_f_6llfuse_fuse_link; /* "src/misc.pxi":76 * fuse_ops.rename = fuse_rename * fuse_ops.link = fuse_link * fuse_ops.open = fuse_open # <<<<<<<<<<<<<< * fuse_ops.read = fuse_read * fuse_ops.write = fuse_write */ __pyx_v_6llfuse_fuse_ops.open = __pyx_f_6llfuse_fuse_open; /* "src/misc.pxi":77 * fuse_ops.link = fuse_link * fuse_ops.open = fuse_open * fuse_ops.read = fuse_read # <<<<<<<<<<<<<< * fuse_ops.write = fuse_write * fuse_ops.flush = fuse_flush */ __pyx_v_6llfuse_fuse_ops.read = __pyx_f_6llfuse_fuse_read; /* "src/misc.pxi":78 * fuse_ops.open = fuse_open * fuse_ops.read = fuse_read * fuse_ops.write = fuse_write # <<<<<<<<<<<<<< * fuse_ops.flush = fuse_flush * fuse_ops.release = fuse_release */ __pyx_v_6llfuse_fuse_ops.write = __pyx_f_6llfuse_fuse_write; /* "src/misc.pxi":79 * fuse_ops.read = fuse_read * fuse_ops.write = fuse_write * fuse_ops.flush = fuse_flush # <<<<<<<<<<<<<< * fuse_ops.release = fuse_release * fuse_ops.fsync = fuse_fsync */ __pyx_v_6llfuse_fuse_ops.flush = __pyx_f_6llfuse_fuse_flush; /* "src/misc.pxi":80 * fuse_ops.write = fuse_write * fuse_ops.flush = fuse_flush * fuse_ops.release = fuse_release # <<<<<<<<<<<<<< * fuse_ops.fsync = fuse_fsync * fuse_ops.opendir = fuse_opendir */ __pyx_v_6llfuse_fuse_ops.release = __pyx_f_6llfuse_fuse_release; /* "src/misc.pxi":81 * fuse_ops.flush = fuse_flush * fuse_ops.release = fuse_release * fuse_ops.fsync = fuse_fsync # <<<<<<<<<<<<<< * fuse_ops.opendir = fuse_opendir * fuse_ops.readdir = fuse_readdir */ __pyx_v_6llfuse_fuse_ops.fsync = __pyx_f_6llfuse_fuse_fsync; /* "src/misc.pxi":82 * fuse_ops.release = fuse_release * fuse_ops.fsync = fuse_fsync * fuse_ops.opendir = fuse_opendir # <<<<<<<<<<<<<< * fuse_ops.readdir = fuse_readdir * fuse_ops.releasedir = fuse_releasedir */ __pyx_v_6llfuse_fuse_ops.opendir = __pyx_f_6llfuse_fuse_opendir; /* "src/misc.pxi":83 * fuse_ops.fsync = fuse_fsync * fuse_ops.opendir = fuse_opendir * fuse_ops.readdir = fuse_readdir # <<<<<<<<<<<<<< * fuse_ops.releasedir = fuse_releasedir * fuse_ops.fsyncdir = fuse_fsyncdir */ __pyx_v_6llfuse_fuse_ops.readdir = __pyx_f_6llfuse_fuse_readdir; /* "src/misc.pxi":84 * fuse_ops.opendir = fuse_opendir * fuse_ops.readdir = fuse_readdir * fuse_ops.releasedir = fuse_releasedir # <<<<<<<<<<<<<< * fuse_ops.fsyncdir = fuse_fsyncdir * fuse_ops.statfs = fuse_statfs */ __pyx_v_6llfuse_fuse_ops.releasedir = __pyx_f_6llfuse_fuse_releasedir; /* "src/misc.pxi":85 * fuse_ops.readdir = fuse_readdir * fuse_ops.releasedir = fuse_releasedir * fuse_ops.fsyncdir = fuse_fsyncdir # <<<<<<<<<<<<<< * fuse_ops.statfs = fuse_statfs * ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) */ __pyx_v_6llfuse_fuse_ops.fsyncdir = __pyx_f_6llfuse_fuse_fsyncdir; /* "src/misc.pxi":86 * fuse_ops.releasedir = fuse_releasedir * fuse_ops.fsyncdir = fuse_fsyncdir * fuse_ops.statfs = fuse_statfs # <<<<<<<<<<<<<< * ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) * ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) */ __pyx_v_6llfuse_fuse_ops.statfs = __pyx_f_6llfuse_fuse_statfs; /* "src/misc.pxi":87 * fuse_ops.fsyncdir = fuse_fsyncdir * fuse_ops.statfs = fuse_statfs * ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) # <<<<<<<<<<<<<< * ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) * ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) */ ASSIGN_DARWIN(__pyx_v_6llfuse_fuse_ops.setxattr, (&__pyx_f_6llfuse_fuse_setxattr_darwin)); /* "src/misc.pxi":88 * fuse_ops.statfs = fuse_statfs * ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) * ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) # <<<<<<<<<<<<<< * ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) * ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) */ ASSIGN_DARWIN(__pyx_v_6llfuse_fuse_ops.getxattr, (&__pyx_f_6llfuse_fuse_getxattr_darwin)); /* "src/misc.pxi":89 * ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) * ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) * ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) # <<<<<<<<<<<<<< * ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) * fuse_ops.listxattr = fuse_listxattr */ ASSIGN_NOT_DARWIN(__pyx_v_6llfuse_fuse_ops.setxattr, (&__pyx_f_6llfuse_fuse_setxattr)); /* "src/misc.pxi":90 * ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) * ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) * ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) # <<<<<<<<<<<<<< * fuse_ops.listxattr = fuse_listxattr * fuse_ops.removexattr = fuse_removexattr */ ASSIGN_NOT_DARWIN(__pyx_v_6llfuse_fuse_ops.getxattr, (&__pyx_f_6llfuse_fuse_getxattr)); /* "src/misc.pxi":91 * ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) * ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) * fuse_ops.listxattr = fuse_listxattr # <<<<<<<<<<<<<< * fuse_ops.removexattr = fuse_removexattr * fuse_ops.access = fuse_access */ __pyx_v_6llfuse_fuse_ops.listxattr = __pyx_f_6llfuse_fuse_listxattr; /* "src/misc.pxi":92 * ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) * fuse_ops.listxattr = fuse_listxattr * fuse_ops.removexattr = fuse_removexattr # <<<<<<<<<<<<<< * fuse_ops.access = fuse_access * fuse_ops.create = fuse_create */ __pyx_v_6llfuse_fuse_ops.removexattr = __pyx_f_6llfuse_fuse_removexattr; /* "src/misc.pxi":93 * fuse_ops.listxattr = fuse_listxattr * fuse_ops.removexattr = fuse_removexattr * fuse_ops.access = fuse_access # <<<<<<<<<<<<<< * fuse_ops.create = fuse_create * fuse_ops.forget_multi = fuse_forget_multi */ __pyx_v_6llfuse_fuse_ops.access = __pyx_f_6llfuse_fuse_access; /* "src/misc.pxi":94 * fuse_ops.removexattr = fuse_removexattr * fuse_ops.access = fuse_access * fuse_ops.create = fuse_create # <<<<<<<<<<<<<< * fuse_ops.forget_multi = fuse_forget_multi * fuse_ops.write_buf = fuse_write_buf */ __pyx_v_6llfuse_fuse_ops.create = __pyx_f_6llfuse_fuse_create; /* "src/misc.pxi":95 * fuse_ops.access = fuse_access * fuse_ops.create = fuse_create * fuse_ops.forget_multi = fuse_forget_multi # <<<<<<<<<<<<<< * fuse_ops.write_buf = fuse_write_buf * */ __pyx_v_6llfuse_fuse_ops.forget_multi = __pyx_f_6llfuse_fuse_forget_multi; /* "src/misc.pxi":96 * fuse_ops.create = fuse_create * fuse_ops.forget_multi = fuse_forget_multi * fuse_ops.write_buf = fuse_write_buf # <<<<<<<<<<<<<< * * cdef make_fuse_args(args, fuse_args* f_args): */ __pyx_v_6llfuse_fuse_ops.write_buf = __pyx_f_6llfuse_fuse_write_buf; /* "src/misc.pxi":57 * return ctx * * cdef void init_fuse_ops(): # <<<<<<<<<<<<<< * '''Initialize fuse_lowlevel_ops structure''' * */ /* function exit code */ __Pyx_RefNannyFinishContext(); } /* "src/misc.pxi":98 * fuse_ops.write_buf = fuse_write_buf * * cdef make_fuse_args(args, fuse_args* f_args): # <<<<<<<<<<<<<< * cdef char* arg * cdef int i */ static PyObject *__pyx_f_6llfuse_make_fuse_args(PyObject *__pyx_v_args, struct fuse_args *__pyx_v_f_args) { char *__pyx_v_arg; int __pyx_v_i; Py_ssize_t __pyx_v_size_s; size_t __pyx_v_size; PyObject *__pyx_v_args_new = NULL; PyObject *__pyx_v_el = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; PyObject *(*__pyx_t_3)(PyObject *); PyObject *__pyx_t_4 = NULL; int __pyx_t_5; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; PyObject *__pyx_t_8; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; int __pyx_t_12; int __pyx_t_13; __Pyx_RefNannySetupContext("make_fuse_args", 0); __Pyx_INCREF(__pyx_v_args); /* "src/misc.pxi":104 * cdef size_t size * * args_new = [ b'Python-LLFUSE' ] # <<<<<<<<<<<<<< * for el in args: * args_new.append(b'-o') */ __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 104, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_kp_b_Python_LLFUSE); __Pyx_GIVEREF(__pyx_kp_b_Python_LLFUSE); PyList_SET_ITEM(__pyx_t_1, 0, __pyx_kp_b_Python_LLFUSE); __pyx_v_args_new = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":105 * * args_new = [ b'Python-LLFUSE' ] * for el in args: # <<<<<<<<<<<<<< * args_new.append(b'-o') * args_new.append(el.encode('us-ascii')) */ if (likely(PyList_CheckExact(__pyx_v_args)) || PyTuple_CheckExact(__pyx_v_args)) { __pyx_t_1 = __pyx_v_args; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = NULL; } else { __pyx_t_2 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 105, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 105, __pyx_L1_error) } for (;;) { if (likely(!__pyx_t_3)) { if (likely(PyList_CheckExact(__pyx_t_1))) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_4 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 105, __pyx_L1_error) #else __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 105, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } else { if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 105, __pyx_L1_error) #else __pyx_t_4 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 105, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); #endif } } else { __pyx_t_4 = __pyx_t_3(__pyx_t_1); if (unlikely(!__pyx_t_4)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(2, 105, __pyx_L1_error) } break; } __Pyx_GOTREF(__pyx_t_4); } __Pyx_XDECREF_SET(__pyx_v_el, __pyx_t_4); __pyx_t_4 = 0; /* "src/misc.pxi":106 * args_new = [ b'Python-LLFUSE' ] * for el in args: * args_new.append(b'-o') # <<<<<<<<<<<<<< * args_new.append(el.encode('us-ascii')) * args = args_new */ __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args_new, __pyx_kp_b_o); if (unlikely(__pyx_t_5 == -1)) __PYX_ERR(2, 106, __pyx_L1_error) /* "src/misc.pxi":107 * for el in args: * args_new.append(b'-o') * args_new.append(el.encode('us-ascii')) # <<<<<<<<<<<<<< * args = args_new * */ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_el, __pyx_n_s_encode); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 107, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__41, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 107, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_5 = __Pyx_PyList_Append(__pyx_v_args_new, __pyx_t_6); if (unlikely(__pyx_t_5 == -1)) __PYX_ERR(2, 107, __pyx_L1_error) __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; /* "src/misc.pxi":105 * * args_new = [ b'Python-LLFUSE' ] * for el in args: # <<<<<<<<<<<<<< * args_new.append(b'-o') * args_new.append(el.encode('us-ascii')) */ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":108 * args_new.append(b'-o') * args_new.append(el.encode('us-ascii')) * args = args_new # <<<<<<<<<<<<<< * * f_args.argc = len(args) */ __Pyx_INCREF(__pyx_v_args_new); __Pyx_DECREF_SET(__pyx_v_args, __pyx_v_args_new); /* "src/misc.pxi":110 * args = args_new * * f_args.argc = len(args) # <<<<<<<<<<<<<< * if f_args.argc == 0: * f_args.argv = NULL */ __pyx_t_2 = PyObject_Length(__pyx_v_args); if (unlikely(__pyx_t_2 == -1)) __PYX_ERR(2, 110, __pyx_L1_error) __pyx_v_f_args->argc = ((int)__pyx_t_2); /* "src/misc.pxi":111 * * f_args.argc = len(args) * if f_args.argc == 0: # <<<<<<<<<<<<<< * f_args.argv = NULL * return */ __pyx_t_7 = ((__pyx_v_f_args->argc == 0) != 0); if (__pyx_t_7) { /* "src/misc.pxi":112 * f_args.argc = len(args) * if f_args.argc == 0: * f_args.argv = NULL # <<<<<<<<<<<<<< * return * */ __pyx_v_f_args->argv = NULL; /* "src/misc.pxi":113 * if f_args.argc == 0: * f_args.argv = NULL * return # <<<<<<<<<<<<<< * * f_args.allocated = 1 */ __Pyx_XDECREF(__pyx_r); __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; /* "src/misc.pxi":111 * * f_args.argc = len(args) * if f_args.argc == 0: # <<<<<<<<<<<<<< * f_args.argv = NULL * return */ } /* "src/misc.pxi":115 * return * * f_args.allocated = 1 # <<<<<<<<<<<<<< * f_args.argv = stdlib.calloc( f_args.argc, sizeof(char*)) * */ __pyx_v_f_args->allocated = 1; /* "src/misc.pxi":116 * * f_args.allocated = 1 * f_args.argv = stdlib.calloc( f_args.argc, sizeof(char*)) # <<<<<<<<<<<<<< * * if f_args.argv is NULL: */ __pyx_v_f_args->argv = ((char **)calloc(((size_t)__pyx_v_f_args->argc), (sizeof(char *)))); /* "src/misc.pxi":118 * f_args.argv = stdlib.calloc( f_args.argc, sizeof(char*)) * * if f_args.argv is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ __pyx_t_7 = ((__pyx_v_f_args->argv == NULL) != 0); if (__pyx_t_7) { /* "src/misc.pxi":119 * * if f_args.argv is NULL: * cpython.exc.PyErr_NoMemory() # <<<<<<<<<<<<<< * * try: */ __pyx_t_8 = PyErr_NoMemory(); if (unlikely(__pyx_t_8 == NULL)) __PYX_ERR(2, 119, __pyx_L1_error) /* "src/misc.pxi":118 * f_args.argv = stdlib.calloc( f_args.argc, sizeof(char*)) * * if f_args.argv is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ } /* "src/misc.pxi":121 * cpython.exc.PyErr_NoMemory() * * try: # <<<<<<<<<<<<<< * for (i, el) in enumerate(args): * PyBytes_AsStringAndSize(el, &arg, &size_s) */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); /*try:*/ { /* "src/misc.pxi":122 * * try: * for (i, el) in enumerate(args): # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(el, &arg, &size_s) * size = size_s # guaranteed positive */ __pyx_t_12 = 0; if (likely(PyList_CheckExact(__pyx_v_args)) || PyTuple_CheckExact(__pyx_v_args)) { __pyx_t_1 = __pyx_v_args; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; __pyx_t_3 = NULL; } else { __pyx_t_2 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_v_args); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 122, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 122, __pyx_L7_error) } for (;;) { if (likely(!__pyx_t_3)) { if (likely(PyList_CheckExact(__pyx_t_1))) { if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_6 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_6); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 122, __pyx_L7_error) #else __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 122, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_6); #endif } else { if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_1)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_6 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_6); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 122, __pyx_L7_error) #else __pyx_t_6 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 122, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_6); #endif } } else { __pyx_t_6 = __pyx_t_3(__pyx_t_1); if (unlikely(!__pyx_t_6)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(2, 122, __pyx_L7_error) } break; } __Pyx_GOTREF(__pyx_t_6); } __Pyx_XDECREF_SET(__pyx_v_el, __pyx_t_6); __pyx_t_6 = 0; __pyx_v_i = __pyx_t_12; __pyx_t_12 = (__pyx_t_12 + 1); /* "src/misc.pxi":123 * try: * for (i, el) in enumerate(args): * PyBytes_AsStringAndSize(el, &arg, &size_s) # <<<<<<<<<<<<<< * size = size_s # guaranteed positive * f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) */ __pyx_t_13 = PyBytes_AsStringAndSize(__pyx_v_el, (&__pyx_v_arg), ((Py_ssize_t *)(&__pyx_v_size_s))); if (unlikely(__pyx_t_13 == -1)) __PYX_ERR(2, 123, __pyx_L7_error) /* "src/misc.pxi":124 * for (i, el) in enumerate(args): * PyBytes_AsStringAndSize(el, &arg, &size_s) * size = size_s # guaranteed positive # <<<<<<<<<<<<<< * f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) * */ __pyx_v_size = ((size_t)__pyx_v_size_s); /* "src/misc.pxi":125 * PyBytes_AsStringAndSize(el, &arg, &size_s) * size = size_s # guaranteed positive * f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) # <<<<<<<<<<<<<< * * if f_args.argv[i] is NULL: */ (__pyx_v_f_args->argv[__pyx_v_i]) = ((char *)malloc(((__pyx_v_size + 1) * (sizeof(char))))); /* "src/misc.pxi":127 * f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) * * if f_args.argv[i] is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ __pyx_t_7 = (((__pyx_v_f_args->argv[__pyx_v_i]) == NULL) != 0); if (__pyx_t_7) { /* "src/misc.pxi":128 * * if f_args.argv[i] is NULL: * cpython.exc.PyErr_NoMemory() # <<<<<<<<<<<<<< * * string.strncpy(f_args.argv[i], arg, size+1) */ __pyx_t_8 = PyErr_NoMemory(); if (unlikely(__pyx_t_8 == NULL)) __PYX_ERR(2, 128, __pyx_L7_error) /* "src/misc.pxi":127 * f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) * * if f_args.argv[i] is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ } /* "src/misc.pxi":130 * cpython.exc.PyErr_NoMemory() * * string.strncpy(f_args.argv[i], arg, size+1) # <<<<<<<<<<<<<< * except: * for i in range(f_args.argc): */ strncpy((__pyx_v_f_args->argv[__pyx_v_i]), __pyx_v_arg, (__pyx_v_size + 1)); /* "src/misc.pxi":122 * * try: * for (i, el) in enumerate(args): # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(el, &arg, &size_s) * size = size_s # guaranteed positive */ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":121 * cpython.exc.PyErr_NoMemory() * * try: # <<<<<<<<<<<<<< * for (i, el) in enumerate(args): * PyBytes_AsStringAndSize(el, &arg, &size_s) */ } __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; goto __pyx_L14_try_end; __pyx_L7_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":131 * * string.strncpy(f_args.argv[i], arg, size+1) * except: # <<<<<<<<<<<<<< * for i in range(f_args.argc): * # Freeing a NULL pointer (if this element has not been allocated */ /*except:*/ { __Pyx_AddTraceback("llfuse.make_fuse_args", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_6, &__pyx_t_4) < 0) __PYX_ERR(2, 131, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_4); /* "src/misc.pxi":132 * string.strncpy(f_args.argv[i], arg, size+1) * except: * for i in range(f_args.argc): # <<<<<<<<<<<<<< * # Freeing a NULL pointer (if this element has not been allocated * # yet) is fine. */ __pyx_t_12 = __pyx_v_f_args->argc; for (__pyx_t_13 = 0; __pyx_t_13 < __pyx_t_12; __pyx_t_13+=1) { __pyx_v_i = __pyx_t_13; /* "src/misc.pxi":135 * # Freeing a NULL pointer (if this element has not been allocated * # yet) is fine. * stdlib.free(f_args.argv[i]) # <<<<<<<<<<<<<< * stdlib.free(f_args.argv) * raise */ free((__pyx_v_f_args->argv[__pyx_v_i])); } /* "src/misc.pxi":136 * # yet) is fine. * stdlib.free(f_args.argv[i]) * stdlib.free(f_args.argv) # <<<<<<<<<<<<<< * raise * */ free(__pyx_v_f_args->argv); /* "src/misc.pxi":137 * stdlib.free(f_args.argv[i]) * stdlib.free(f_args.argv) * raise # <<<<<<<<<<<<<< * * cdef class Lock: */ __Pyx_GIVEREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_4); __Pyx_ErrRestoreWithState(__pyx_t_1, __pyx_t_6, __pyx_t_4); __pyx_t_1 = 0; __pyx_t_6 = 0; __pyx_t_4 = 0; __PYX_ERR(2, 137, __pyx_L9_except_error) } __pyx_L9_except_error:; /* "src/misc.pxi":121 * cpython.exc.PyErr_NoMemory() * * try: # <<<<<<<<<<<<<< * for (i, el) in enumerate(args): * PyBytes_AsStringAndSize(el, &arg, &size_s) */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); goto __pyx_L1_error; __pyx_L14_try_end:; } /* "src/misc.pxi":98 * fuse_ops.write_buf = fuse_write_buf * * cdef make_fuse_args(args, fuse_args* f_args): # <<<<<<<<<<<<<< * cdef char* arg * cdef int i */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("llfuse.make_fuse_args", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_args_new); __Pyx_XDECREF(__pyx_v_el); __Pyx_XDECREF(__pyx_v_args); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":145 * ''' * * def __init__(self): # <<<<<<<<<<<<<< * raise TypeError('You should not instantiate this class, use the ' * 'provided instance instead.') */ /* Python wrapper */ static int __pyx_pw_6llfuse_4Lock_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_4Lock_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__init__ (wrapper)", 0); if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) { __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;} if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 0))) return -1; __pyx_r = __pyx_pf_6llfuse_4Lock___init__(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_4Lock___init__(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__init__", 0); /* "src/misc.pxi":146 * * def __init__(self): * raise TypeError('You should not instantiate this class, use the ' # <<<<<<<<<<<<<< * 'provided instance instead.') * */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__42, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 146, __pyx_L1_error) /* "src/misc.pxi":145 * ''' * * def __init__(self): # <<<<<<<<<<<<<< * raise TypeError('You should not instantiate this class, use the ' * 'provided instance instead.') */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.Lock.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":149 * 'provided instance instead.') * * def acquire(self, timeout=None): # <<<<<<<<<<<<<< * '''Acquire global lock * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_3acquire(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_4Lock_2acquire[] = "Lock.acquire(self, timeout=None)\nAcquire global lock\n\n If *timeout* is not None, and the lock could not be acquired\n after waiting for *timeout* seconds, return False. Otherwise\n return True.\n "; static PyObject *__pyx_pw_6llfuse_4Lock_3acquire(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_timeout = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("acquire (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_timeout,0}; PyObject* values[1] = {0}; values[0] = ((PyObject *)Py_None); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_timeout); if (value) { values[0] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "acquire") < 0)) __PYX_ERR(2, 149, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_timeout = values[0]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("acquire", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(2, 149, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Lock.acquire", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_4Lock_2acquire(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self), __pyx_v_timeout); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_2acquire(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self, PyObject *__pyx_v_timeout) { int __pyx_v_ret; int __pyx_v_timeout_c; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; int __pyx_t_2; int __pyx_t_3; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; __Pyx_RefNannySetupContext("acquire", 0); /* "src/misc.pxi":160 * cdef int timeout_c * * if timeout is None: # <<<<<<<<<<<<<< * timeout_c = 0 * else: */ __pyx_t_1 = (__pyx_v_timeout == Py_None); __pyx_t_2 = (__pyx_t_1 != 0); if (__pyx_t_2) { /* "src/misc.pxi":161 * * if timeout is None: * timeout_c = 0 # <<<<<<<<<<<<<< * else: * timeout_c = timeout */ __pyx_v_timeout_c = 0; /* "src/misc.pxi":160 * cdef int timeout_c * * if timeout is None: # <<<<<<<<<<<<<< * timeout_c = 0 * else: */ goto __pyx_L3; } /* "src/misc.pxi":163 * timeout_c = 0 * else: * timeout_c = timeout # <<<<<<<<<<<<<< * * with nogil: */ /*else*/ { __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_timeout); if (unlikely((__pyx_t_3 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 163, __pyx_L1_error) __pyx_v_timeout_c = __pyx_t_3; } __pyx_L3:; /* "src/misc.pxi":165 * timeout_c = timeout * * with nogil: # <<<<<<<<<<<<<< * ret = acquire(timeout_c) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":166 * * with nogil: * ret = acquire(timeout_c) # <<<<<<<<<<<<<< * * if ret == 0: */ __pyx_v_ret = acquire(__pyx_v_timeout_c); } /* "src/misc.pxi":165 * timeout_c = timeout * * with nogil: # <<<<<<<<<<<<<< * ret = acquire(timeout_c) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L6; } __pyx_L6:; } } /* "src/misc.pxi":168 * ret = acquire(timeout_c) * * if ret == 0: # <<<<<<<<<<<<<< * return True * elif ret == ETIMEDOUT and timeout != 0: */ __pyx_t_2 = ((__pyx_v_ret == 0) != 0); if (__pyx_t_2) { /* "src/misc.pxi":169 * * if ret == 0: * return True # <<<<<<<<<<<<<< * elif ret == ETIMEDOUT and timeout != 0: * return False */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(Py_True); __pyx_r = Py_True; goto __pyx_L0; /* "src/misc.pxi":168 * ret = acquire(timeout_c) * * if ret == 0: # <<<<<<<<<<<<<< * return True * elif ret == ETIMEDOUT and timeout != 0: */ } /* "src/misc.pxi":170 * if ret == 0: * return True * elif ret == ETIMEDOUT and timeout != 0: # <<<<<<<<<<<<<< * return False * elif ret == EDEADLK: */ __pyx_t_1 = ((__pyx_v_ret == ETIMEDOUT) != 0); if (__pyx_t_1) { } else { __pyx_t_2 = __pyx_t_1; goto __pyx_L8_bool_binop_done; } __pyx_t_4 = PyObject_RichCompare(__pyx_v_timeout, __pyx_int_0, Py_NE); __Pyx_XGOTREF(__pyx_t_4); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 170, __pyx_L1_error) __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(2, 170, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_2 = __pyx_t_1; __pyx_L8_bool_binop_done:; if (__pyx_t_2) { /* "src/misc.pxi":171 * return True * elif ret == ETIMEDOUT and timeout != 0: * return False # <<<<<<<<<<<<<< * elif ret == EDEADLK: * raise RuntimeError("Global lock cannot be acquired more than once") */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(Py_False); __pyx_r = Py_False; goto __pyx_L0; /* "src/misc.pxi":170 * if ret == 0: * return True * elif ret == ETIMEDOUT and timeout != 0: # <<<<<<<<<<<<<< * return False * elif ret == EDEADLK: */ } /* "src/misc.pxi":172 * elif ret == ETIMEDOUT and timeout != 0: * return False * elif ret == EDEADLK: # <<<<<<<<<<<<<< * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: */ __pyx_t_2 = ((__pyx_v_ret == EDEADLK) != 0); if (__pyx_t_2) { /* "src/misc.pxi":173 * return False * elif ret == EDEADLK: * raise RuntimeError("Global lock cannot be acquired more than once") # <<<<<<<<<<<<<< * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") */ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__43, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 173, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 173, __pyx_L1_error) /* "src/misc.pxi":172 * elif ret == ETIMEDOUT and timeout != 0: * return False * elif ret == EDEADLK: # <<<<<<<<<<<<<< * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: */ } /* "src/misc.pxi":174 * elif ret == EDEADLK: * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: # <<<<<<<<<<<<<< * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: */ __pyx_t_2 = ((__pyx_v_ret == EPROTO) != 0); if (__pyx_t_2) { /* "src/misc.pxi":175 * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__44, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 175, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 175, __pyx_L1_error) /* "src/misc.pxi":174 * elif ret == EDEADLK: * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: # <<<<<<<<<<<<<< * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: */ } /* "src/misc.pxi":176 * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ __pyx_t_2 = ((__pyx_v_ret == EINVAL) != 0); if (__pyx_t_2) { /* "src/misc.pxi":177 * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__45, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 177, __pyx_L1_error) /* "src/misc.pxi":176 * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ } /* "src/misc.pxi":179 * raise RuntimeError("Lock not initialized") * else: * raise RuntimeError(strerror(ret)) # <<<<<<<<<<<<<< * * def release(self): */ /*else*/ { __pyx_t_4 = __pyx_f_6llfuse_strerror(__pyx_v_ret); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_t_5, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 179, __pyx_L1_error) } /* "src/misc.pxi":149 * 'provided instance instead.') * * def acquire(self, timeout=None): # <<<<<<<<<<<<<< * '''Acquire global lock * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("llfuse.Lock.acquire", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":181 * raise RuntimeError(strerror(ret)) * * def release(self): # <<<<<<<<<<<<<< * '''Release global lock''' * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_5release(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_4Lock_4release[] = "Lock.release(self)\nRelease global lock"; static PyObject *__pyx_pw_6llfuse_4Lock_5release(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("release (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_4Lock_4release(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_4release(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self) { int __pyx_v_ret; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("release", 0); /* "src/misc.pxi":185 * * cdef int ret * with nogil: # <<<<<<<<<<<<<< * ret = release() * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":186 * cdef int ret * with nogil: * ret = release() # <<<<<<<<<<<<<< * * if ret == 0: */ __pyx_v_ret = release(); } /* "src/misc.pxi":185 * * cdef int ret * with nogil: # <<<<<<<<<<<<<< * ret = release() * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L5; } __pyx_L5:; } } /* "src/misc.pxi":188 * ret = release() * * if ret == 0: # <<<<<<<<<<<<<< * return * elif ret == EPERM: */ switch (__pyx_v_ret) { case 0: /* "src/misc.pxi":189 * * if ret == 0: * return # <<<<<<<<<<<<<< * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") */ __Pyx_XDECREF(__pyx_r); __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; /* "src/misc.pxi":188 * ret = release() * * if ret == 0: # <<<<<<<<<<<<<< * return * elif ret == EPERM: */ break; /* "src/misc.pxi":190 * if ret == 0: * return * elif ret == EPERM: # <<<<<<<<<<<<<< * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: */ case EPERM: /* "src/misc.pxi":191 * return * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__46, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 191, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 191, __pyx_L1_error) /* "src/misc.pxi":190 * if ret == 0: * return * elif ret == EPERM: # <<<<<<<<<<<<<< * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: */ break; /* "src/misc.pxi":192 * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ case EINVAL: /* "src/misc.pxi":193 * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__47, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 193, __pyx_L1_error) /* "src/misc.pxi":192 * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ break; default: /* "src/misc.pxi":195 * raise RuntimeError("Lock not initialized") * else: * raise RuntimeError(strerror(ret)) # <<<<<<<<<<<<<< * * def yield_(self, count=1): */ __pyx_t_1 = __pyx_f_6llfuse_strerror(__pyx_v_ret); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 195, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 195, __pyx_L1_error) break; } /* "src/misc.pxi":181 * raise RuntimeError(strerror(ret)) * * def release(self): # <<<<<<<<<<<<<< * '''Release global lock''' * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Lock.release", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":197 * raise RuntimeError(strerror(ret)) * * def yield_(self, count=1): # <<<<<<<<<<<<<< * '''Yield global lock to a different thread * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_7yield_(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_4Lock_6yield_[] = "Lock.yield_(self, count=1)\nYield global lock to a different thread\n\n A call to `~Lock.yield_` is roughly similar to::\n\n for i in range(count):\n if no_threads_waiting_for(lock):\n break\n lock.release()\n lock.acquire()\n\n However, when using `~Lock.yield_` it is guaranteed that the lock will\n actually be passed to a different thread (the above pseude-code may\n result in the same thread re-acquiring the lock *count* times).\n "; static PyObject *__pyx_pw_6llfuse_4Lock_7yield_(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_count = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("yield_ (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_count,0}; PyObject* values[1] = {0}; values[0] = ((PyObject *)__pyx_int_1); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_count); if (value) { values[0] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "yield_") < 0)) __PYX_ERR(2, 197, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_count = values[0]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("yield_", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(2, 197, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Lock.yield_", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_4Lock_6yield_(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self), __pyx_v_count); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_6yield_(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self, PyObject *__pyx_v_count) { int __pyx_v_ret; int __pyx_v_count_c; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("yield_", 0); /* "src/misc.pxi":216 * cdef int count_c * * count_c = count # <<<<<<<<<<<<<< * with nogil: * ret = c_yield(count_c) */ __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_count); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 216, __pyx_L1_error) __pyx_v_count_c = __pyx_t_1; /* "src/misc.pxi":217 * * count_c = count * with nogil: # <<<<<<<<<<<<<< * ret = c_yield(count_c) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":218 * count_c = count * with nogil: * ret = c_yield(count_c) # <<<<<<<<<<<<<< * * if ret == 0: */ __pyx_v_ret = c_yield(__pyx_v_count_c); } /* "src/misc.pxi":217 * * count_c = count * with nogil: # <<<<<<<<<<<<<< * ret = c_yield(count_c) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L5; } __pyx_L5:; } } /* "src/misc.pxi":220 * ret = c_yield(count_c) * * if ret == 0: # <<<<<<<<<<<<<< * return * elif ret == EPERM: */ switch (__pyx_v_ret) { case 0: /* "src/misc.pxi":221 * * if ret == 0: * return # <<<<<<<<<<<<<< * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") */ __Pyx_XDECREF(__pyx_r); __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; /* "src/misc.pxi":220 * ret = c_yield(count_c) * * if ret == 0: # <<<<<<<<<<<<<< * return * elif ret == EPERM: */ break; /* "src/misc.pxi":222 * if ret == 0: * return * elif ret == EPERM: # <<<<<<<<<<<<<< * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: */ case EPERM: /* "src/misc.pxi":223 * return * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") # <<<<<<<<<<<<<< * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__48, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 223, __pyx_L1_error) /* "src/misc.pxi":222 * if ret == 0: * return * elif ret == EPERM: # <<<<<<<<<<<<<< * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: */ break; /* "src/misc.pxi":224 * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: # <<<<<<<<<<<<<< * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: */ case EPROTO: /* "src/misc.pxi":225 * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") # <<<<<<<<<<<<<< * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__49, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 225, __pyx_L1_error) /* "src/misc.pxi":224 * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: # <<<<<<<<<<<<<< * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: */ break; /* "src/misc.pxi":226 * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: # <<<<<<<<<<<<<< * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: */ case ENOMSG: /* "src/misc.pxi":227 * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__50, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 227, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 227, __pyx_L1_error) /* "src/misc.pxi":226 * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: # <<<<<<<<<<<<<< * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: */ break; /* "src/misc.pxi":228 * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ case EINVAL: /* "src/misc.pxi":229 * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__51, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 229, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 229, __pyx_L1_error) /* "src/misc.pxi":228 * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: # <<<<<<<<<<<<<< * raise RuntimeError("Lock not initialized") * else: */ break; default: /* "src/misc.pxi":231 * raise RuntimeError("Lock not initialized") * else: * raise RuntimeError(strerror(ret)) # <<<<<<<<<<<<<< * * def __enter__(self): */ __pyx_t_2 = __pyx_f_6llfuse_strerror(__pyx_v_ret); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 231, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 231, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 231, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 231, __pyx_L1_error) break; } /* "src/misc.pxi":197 * raise RuntimeError(strerror(ret)) * * def yield_(self, count=1): # <<<<<<<<<<<<<< * '''Yield global lock to a different thread * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.Lock.yield_", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":233 * raise RuntimeError(strerror(ret)) * * def __enter__(self): # <<<<<<<<<<<<<< * self.acquire() * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_9__enter__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_4Lock_8__enter__[] = "Lock.__enter__(self)"; static PyObject *__pyx_pw_6llfuse_4Lock_9__enter__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__enter__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_4Lock_8__enter__(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_8__enter__(struct __pyx_obj_6llfuse_Lock *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__enter__", 0); /* "src/misc.pxi":234 * * def __enter__(self): * self.acquire() # <<<<<<<<<<<<<< * * def __exit__(self, exc_type, exc_val, exc_tb): */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_acquire); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 234, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (__pyx_t_3) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 234, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 234, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":233 * raise RuntimeError(strerror(ret)) * * def __enter__(self): # <<<<<<<<<<<<<< * self.acquire() * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.Lock.__enter__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":236 * self.acquire() * * def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<< * self.release() * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_11__exit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_4Lock_10__exit__[] = "Lock.__exit__(self, exc_type, exc_val, exc_tb)"; static PyObject *__pyx_pw_6llfuse_4Lock_11__exit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_exc_type = 0; CYTHON_UNUSED PyObject *__pyx_v_exc_val = 0; CYTHON_UNUSED PyObject *__pyx_v_exc_tb = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__exit__ (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_exc_type,&__pyx_n_s_exc_val,&__pyx_n_s_exc_tb,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_type)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_val)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 1); __PYX_ERR(2, 236, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_exc_tb)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, 2); __PYX_ERR(2, 236, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__exit__") < 0)) __PYX_ERR(2, 236, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_exc_type = values[0]; __pyx_v_exc_val = values[1]; __pyx_v_exc_tb = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("__exit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(2, 236, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.Lock.__exit__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_4Lock_10__exit__(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self), __pyx_v_exc_type, __pyx_v_exc_val, __pyx_v_exc_tb); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_10__exit__(struct __pyx_obj_6llfuse_Lock *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_exc_type, CYTHON_UNUSED PyObject *__pyx_v_exc_val, CYTHON_UNUSED PyObject *__pyx_v_exc_tb) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__exit__", 0); /* "src/misc.pxi":237 * * def __exit__(self, exc_type, exc_val, exc_tb): * self.release() # <<<<<<<<<<<<<< * * def __getstate__(self): */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_release); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 237, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (__pyx_t_3) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 237, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 237, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":236 * self.acquire() * * def __exit__(self, exc_type, exc_val, exc_tb): # <<<<<<<<<<<<<< * self.release() * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.Lock.__exit__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":239 * self.release() * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("Lock instances can't be pickled") * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4Lock_13__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_4Lock_12__getstate__[] = "Lock.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_4Lock_13__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_4Lock_12__getstate__(((struct __pyx_obj_6llfuse_Lock *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4Lock_12__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_Lock *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":240 * * def __getstate__(self): * raise PicklingError("Lock instances can't be pickled") # <<<<<<<<<<<<<< * * cdef class NoLockManager: */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_PicklingError); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__52, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 240, __pyx_L1_error) /* "src/misc.pxi":239 * self.release() * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("Lock instances can't be pickled") * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.Lock.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":245 * '''Context manager to execute code while the global lock is released''' * * def __init__(self): # <<<<<<<<<<<<<< * raise TypeError('You should not instantiate this class, use the ' * 'provided instance instead.') */ /* Python wrapper */ static int __pyx_pw_6llfuse_13NoLockManager_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_13NoLockManager_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__init__ (wrapper)", 0); if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) { __Pyx_RaiseArgtupleInvalid("__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;} if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__init__", 0))) return -1; __pyx_r = __pyx_pf_6llfuse_13NoLockManager___init__(((struct __pyx_obj_6llfuse_NoLockManager *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_13NoLockManager___init__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__init__", 0); /* "src/misc.pxi":246 * * def __init__(self): * raise TypeError('You should not instantiate this class, use the ' # <<<<<<<<<<<<<< * 'provided instance instead.') * */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__53, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 246, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 246, __pyx_L1_error) /* "src/misc.pxi":245 * '''Context manager to execute code while the global lock is released''' * * def __init__(self): # <<<<<<<<<<<<<< * raise TypeError('You should not instantiate this class, use the ' * 'provided instance instead.') */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.NoLockManager.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":249 * 'provided instance instead.') * * def __enter__ (self): # <<<<<<<<<<<<<< * lock.release() * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13NoLockManager_3__enter__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_13NoLockManager_2__enter__[] = "NoLockManager.__enter__(self)"; static PyObject *__pyx_pw_6llfuse_13NoLockManager_3__enter__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__enter__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13NoLockManager_2__enter__(((struct __pyx_obj_6llfuse_NoLockManager *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13NoLockManager_2__enter__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__enter__", 0); /* "src/misc.pxi":250 * * def __enter__ (self): * lock.release() # <<<<<<<<<<<<<< * * def __exit__(self, *a): */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_release); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 250, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_2)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); } } if (__pyx_t_2) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 250, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 250, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":249 * 'provided instance instead.') * * def __enter__ (self): # <<<<<<<<<<<<<< * lock.release() * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.NoLockManager.__enter__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":252 * lock.release() * * def __exit__(self, *a): # <<<<<<<<<<<<<< * lock.acquire() * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13NoLockManager_5__exit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_13NoLockManager_4__exit__[] = "NoLockManager.__exit__(self, *a)"; static PyObject *__pyx_pw_6llfuse_13NoLockManager_5__exit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { CYTHON_UNUSED PyObject *__pyx_v_a = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__exit__ (wrapper)", 0); if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__exit__", 0))) return NULL; __Pyx_INCREF(__pyx_args); __pyx_v_a = __pyx_args; __pyx_r = __pyx_pf_6llfuse_13NoLockManager_4__exit__(((struct __pyx_obj_6llfuse_NoLockManager *)__pyx_v_self), __pyx_v_a); /* function exit code */ __Pyx_XDECREF(__pyx_v_a); __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13NoLockManager_4__exit__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v_a) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__exit__", 0); /* "src/misc.pxi":253 * * def __exit__(self, *a): * lock.acquire() # <<<<<<<<<<<<<< * * def __getstate__(self): */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_lock); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 253, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_acquire); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 253, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_2)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); } } if (__pyx_t_2) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 253, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 253, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":252 * lock.release() * * def __exit__(self, *a): # <<<<<<<<<<<<<< * lock.acquire() * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.NoLockManager.__exit__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":255 * lock.acquire() * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("NoLockManager instances can't be pickled") * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13NoLockManager_7__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_13NoLockManager_6__getstate__[] = "NoLockManager.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_13NoLockManager_7__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13NoLockManager_6__getstate__(((struct __pyx_obj_6llfuse_NoLockManager *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13NoLockManager_6__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_NoLockManager *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":256 * * def __getstate__(self): * raise PicklingError("NoLockManager instances can't be pickled") # <<<<<<<<<<<<<< * * def _notify_loop(): */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_PicklingError); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 256, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__54, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 256, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 256, __pyx_L1_error) /* "src/misc.pxi":255 * lock.acquire() * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("NoLockManager instances can't be pickled") * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.NoLockManager.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":258 * raise PicklingError("NoLockManager instances can't be pickled") * * def _notify_loop(): # <<<<<<<<<<<<<< * '''Read notifications from queue and send to FUSE kernel module''' * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_1_notify_loop(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse__notify_loop[] = "_notify_loop()\nRead notifications from queue and send to FUSE kernel module"; static PyMethodDef __pyx_mdef_6llfuse_1_notify_loop = {"_notify_loop", (PyCFunction)__pyx_pw_6llfuse_1_notify_loop, METH_NOARGS, __pyx_doc_6llfuse__notify_loop}; static PyObject *__pyx_pw_6llfuse_1_notify_loop(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("_notify_loop (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse__notify_loop(__pyx_self); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse__notify_loop(CYTHON_UNUSED PyObject *__pyx_self) { Py_ssize_t __pyx_v_len_; char *__pyx_v_cname; struct __pyx_obj_6llfuse_NotifyRequest *__pyx_v_req = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; int __pyx_t_4; int __pyx_t_5; int __pyx_t_6; __Pyx_RefNannySetupContext("_notify_loop", 0); /* "src/misc.pxi":265 * cdef NotifyRequest req * * while True: # <<<<<<<<<<<<<< * req = _notify_queue.get() * if req is None: */ while (1) { /* "src/misc.pxi":266 * * while True: * req = _notify_queue.get() # <<<<<<<<<<<<<< * if req is None: * return */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse__notify_queue, __pyx_n_s_get); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (__pyx_t_3) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 266, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 266, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_6llfuse_NotifyRequest))))) __PYX_ERR(2, 266, __pyx_L1_error) __Pyx_XDECREF_SET(__pyx_v_req, ((struct __pyx_obj_6llfuse_NotifyRequest *)__pyx_t_1)); __pyx_t_1 = 0; /* "src/misc.pxi":267 * while True: * req = _notify_queue.get() * if req is None: # <<<<<<<<<<<<<< * return * */ __pyx_t_4 = (((PyObject *)__pyx_v_req) == Py_None); __pyx_t_5 = (__pyx_t_4 != 0); if (__pyx_t_5) { /* "src/misc.pxi":268 * req = _notify_queue.get() * if req is None: * return # <<<<<<<<<<<<<< * * if req.kind == NOTIFY_INVAL_INODE: */ __Pyx_XDECREF(__pyx_r); __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; /* "src/misc.pxi":267 * while True: * req = _notify_queue.get() * if req is None: # <<<<<<<<<<<<<< * return * */ } /* "src/misc.pxi":270 * return * * if req.kind == NOTIFY_INVAL_INODE: # <<<<<<<<<<<<<< * if req.attr_only: * with nogil: */ switch (__pyx_v_req->kind) { case NOTIFY_INVAL_INODE: /* "src/misc.pxi":271 * * if req.kind == NOTIFY_INVAL_INODE: * if req.attr_only: # <<<<<<<<<<<<<< * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) */ __pyx_t_5 = (__pyx_v_req->attr_only != 0); if (__pyx_t_5) { /* "src/misc.pxi":272 * if req.kind == NOTIFY_INVAL_INODE: * if req.attr_only: * with nogil: # <<<<<<<<<<<<<< * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) * else: */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":273 * if req.attr_only: * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) # <<<<<<<<<<<<<< * else: * with nogil: */ fuse_lowlevel_notify_inval_inode(__pyx_v_6llfuse_channel, __pyx_v_req->ino, -1L, 0); } /* "src/misc.pxi":272 * if req.kind == NOTIFY_INVAL_INODE: * if req.attr_only: * with nogil: # <<<<<<<<<<<<<< * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) * else: */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L11; } __pyx_L11:; } } /* "src/misc.pxi":271 * * if req.kind == NOTIFY_INVAL_INODE: * if req.attr_only: # <<<<<<<<<<<<<< * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) */ goto __pyx_L6; } /* "src/misc.pxi":275 * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) * else: * with nogil: # <<<<<<<<<<<<<< * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) * elif req.kind == NOTIFY_INVAL_ENTRY: */ /*else*/ { { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":276 * else: * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) # <<<<<<<<<<<<<< * elif req.kind == NOTIFY_INVAL_ENTRY: * PyBytes_AsStringAndSize(req.name, &cname, &len_) */ fuse_lowlevel_notify_inval_inode(__pyx_v_6llfuse_channel, __pyx_v_req->ino, 0, 0); } /* "src/misc.pxi":275 * fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) * else: * with nogil: # <<<<<<<<<<<<<< * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) * elif req.kind == NOTIFY_INVAL_ENTRY: */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L16; } __pyx_L16:; } } } __pyx_L6:; /* "src/misc.pxi":270 * return * * if req.kind == NOTIFY_INVAL_INODE: # <<<<<<<<<<<<<< * if req.attr_only: * with nogil: */ break; /* "src/misc.pxi":277 * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) * elif req.kind == NOTIFY_INVAL_ENTRY: # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(req.name, &cname, &len_) * with nogil: */ case NOTIFY_INVAL_ENTRY: /* "src/misc.pxi":278 * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) * elif req.kind == NOTIFY_INVAL_ENTRY: * PyBytes_AsStringAndSize(req.name, &cname, &len_) # <<<<<<<<<<<<<< * with nogil: * # len_ is guaranteed positive */ __pyx_t_1 = __pyx_v_req->name; __Pyx_INCREF(__pyx_t_1); __pyx_t_6 = PyBytes_AsStringAndSize(__pyx_t_1, (&__pyx_v_cname), ((Py_ssize_t *)(&__pyx_v_len_))); if (unlikely(__pyx_t_6 == -1)) __PYX_ERR(2, 278, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":279 * elif req.kind == NOTIFY_INVAL_ENTRY: * PyBytes_AsStringAndSize(req.name, &cname, &len_) * with nogil: # <<<<<<<<<<<<<< * # len_ is guaranteed positive * fuse_lowlevel_notify_inval_entry(channel, req.ino, cname, */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/misc.pxi":281 * with nogil: * # len_ is guaranteed positive * fuse_lowlevel_notify_inval_entry(channel, req.ino, cname, # <<<<<<<<<<<<<< * len_) * else: */ fuse_lowlevel_notify_inval_entry(__pyx_v_6llfuse_channel, __pyx_v_req->ino, __pyx_v_cname, ((size_t)__pyx_v_len_)); } /* "src/misc.pxi":279 * elif req.kind == NOTIFY_INVAL_ENTRY: * PyBytes_AsStringAndSize(req.name, &cname, &len_) * with nogil: # <<<<<<<<<<<<<< * # len_ is guaranteed positive * fuse_lowlevel_notify_inval_entry(channel, req.ino, cname, */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L21; } __pyx_L21:; } } /* "src/misc.pxi":277 * with nogil: * fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) * elif req.kind == NOTIFY_INVAL_ENTRY: # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(req.name, &cname, &len_) * with nogil: */ break; default: /* "src/misc.pxi":284 * len_) * else: * raise RuntimeError("Weird request kind received: %d", req.kind) # <<<<<<<<<<<<<< * * cdef str2bytes(s): */ __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_req->kind); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 284, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 284, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_kp_u_Weird_request_kind_received_d); __Pyx_GIVEREF(__pyx_kp_u_Weird_request_kind_received_d); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_kp_u_Weird_request_kind_received_d); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 284, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(2, 284, __pyx_L1_error) break; } } /* "src/misc.pxi":258 * raise PicklingError("NoLockManager instances can't be pickled") * * def _notify_loop(): # <<<<<<<<<<<<<< * '''Read notifications from queue and send to FUSE kernel module''' * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse._notify_loop", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_req); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":286 * raise RuntimeError("Weird request kind received: %d", req.kind) * * cdef str2bytes(s): # <<<<<<<<<<<<<< * '''Convert *s* to bytes * */ static PyObject *__pyx_f_6llfuse_str2bytes(PyObject *__pyx_v_s) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; __Pyx_RefNannySetupContext("str2bytes", 0); /* "src/misc.pxi":293 * ''' * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * return s * else: */ __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0); if (__pyx_t_1) { /* "src/misc.pxi":294 * * if PY_MAJOR_VERSION < 3: * return s # <<<<<<<<<<<<<< * else: * return s.encode(fse, 'surrogateescape') */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_s); __pyx_r = __pyx_v_s; goto __pyx_L0; /* "src/misc.pxi":293 * ''' * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * return s * else: */ } /* "src/misc.pxi":296 * return s * else: * return s.encode(fse, 'surrogateescape') # <<<<<<<<<<<<<< * * cdef bytes2str(s): */ /*else*/ { __Pyx_XDECREF(__pyx_r); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_s, __pyx_n_s_encode); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_fse); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_4, __pyx_n_u_surrogateescape}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_4, __pyx_n_u_surrogateescape}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_t_4); __Pyx_INCREF(__pyx_n_u_surrogateescape); __Pyx_GIVEREF(__pyx_n_u_surrogateescape); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_n_u_surrogateescape); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; } /* "src/misc.pxi":286 * raise RuntimeError("Weird request kind received: %d", req.kind) * * cdef str2bytes(s): # <<<<<<<<<<<<<< * '''Convert *s* to bytes * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("llfuse.str2bytes", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":298 * return s.encode(fse, 'surrogateescape') * * cdef bytes2str(s): # <<<<<<<<<<<<<< * '''Convert *s* to str * */ static PyObject *__pyx_f_6llfuse_bytes2str(PyObject *__pyx_v_s) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; __Pyx_RefNannySetupContext("bytes2str", 0); /* "src/misc.pxi":305 * ''' * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * return s * else: */ __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0); if (__pyx_t_1) { /* "src/misc.pxi":306 * * if PY_MAJOR_VERSION < 3: * return s # <<<<<<<<<<<<<< * else: * return s.decode(fse, 'surrogateescape') */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_s); __pyx_r = __pyx_v_s; goto __pyx_L0; /* "src/misc.pxi":305 * ''' * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * return s * else: */ } /* "src/misc.pxi":308 * return s * else: * return s.decode(fse, 'surrogateescape') # <<<<<<<<<<<<<< * * cdef strerror(int errno): */ /*else*/ { __Pyx_XDECREF(__pyx_r); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_s, __pyx_n_s_decode); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_fse); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; __pyx_t_6 = 0; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); __pyx_t_6 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_4, __pyx_n_u_surrogateescape}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_4, __pyx_n_u_surrogateescape}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_7 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); if (__pyx_t_5) { __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL; } __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_t_4); __Pyx_INCREF(__pyx_n_u_surrogateescape); __Pyx_GIVEREF(__pyx_n_u_surrogateescape); PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, __pyx_n_u_surrogateescape); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_r = __pyx_t_2; __pyx_t_2 = 0; goto __pyx_L0; } /* "src/misc.pxi":298 * return s.encode(fse, 'surrogateescape') * * cdef bytes2str(s): # <<<<<<<<<<<<<< * '''Convert *s* to str * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("llfuse.bytes2str", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":310 * return s.decode(fse, 'surrogateescape') * * cdef strerror(int errno): # <<<<<<<<<<<<<< * try: * return os.strerror(errno) */ static PyObject *__pyx_f_6llfuse_strerror(int __pyx_v_errno) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; int __pyx_t_9; __Pyx_RefNannySetupContext("strerror", 0); /* "src/misc.pxi":311 * * cdef strerror(int errno): * try: # <<<<<<<<<<<<<< * return os.strerror(errno) * except ValueError: */ { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3); __Pyx_XGOTREF(__pyx_t_1); __Pyx_XGOTREF(__pyx_t_2); __Pyx_XGOTREF(__pyx_t_3); /*try:*/ { /* "src/misc.pxi":312 * cdef strerror(int errno): * try: * return os.strerror(errno) # <<<<<<<<<<<<<< * except ValueError: * return 'errno: %d' % errno */ __Pyx_XDECREF(__pyx_r); __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_strerror); if (unlikely(!__pyx_t_6)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_errno); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_6); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_6, function); } } if (!__pyx_t_7) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_6, __pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_t_5}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_t_5}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif { __pyx_t_8 = PyTuple_New(1+1); if (unlikely(!__pyx_t_8)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL; __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_8, 0+1, __pyx_t_5); __pyx_t_5 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 312, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } } __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L7_try_return; /* "src/misc.pxi":311 * * cdef strerror(int errno): * try: # <<<<<<<<<<<<<< * return os.strerror(errno) * except ValueError: */ } __pyx_L3_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/misc.pxi":313 * try: * return os.strerror(errno) * except ValueError: # <<<<<<<<<<<<<< * return 'errno: %d' % errno * */ __pyx_t_9 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_ValueError); if (__pyx_t_9) { __Pyx_AddTraceback("llfuse.strerror", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_6, &__pyx_t_8) < 0) __PYX_ERR(2, 313, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_6); __Pyx_GOTREF(__pyx_t_8); /* "src/misc.pxi":314 * return os.strerror(errno) * except ValueError: * return 'errno: %d' % errno # <<<<<<<<<<<<<< * * @cython.freelist(10) */ __Pyx_XDECREF(__pyx_r); __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_errno); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 314, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = PyUnicode_Format(__pyx_kp_u_errno_d, __pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(2, 314, __pyx_L5_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_r = __pyx_t_7; __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L6_except_return; } goto __pyx_L5_except_error; __pyx_L5_except_error:; /* "src/misc.pxi":311 * * cdef strerror(int errno): * try: # <<<<<<<<<<<<<< * return os.strerror(errno) * except ValueError: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L1_error; __pyx_L7_try_return:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L0; __pyx_L6_except_return:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_XGIVEREF(__pyx_t_3); __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3); goto __pyx_L0; } /* "src/misc.pxi":310 * return s.decode(fse, 'surrogateescape') * * cdef strerror(int errno): # <<<<<<<<<<<<<< * try: * return os.strerror(errno) */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_AddTraceback("llfuse.strerror", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":329 * cdef readonly mode_t umask * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("RequestContext instances can't be pickled") * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_14RequestContext_1__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_14RequestContext___getstate__[] = "RequestContext.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_14RequestContext_1__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_14RequestContext___getstate__(((struct __pyx_obj_6llfuse_RequestContext *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14RequestContext___getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":330 * * def __getstate__(self): * raise PicklingError("RequestContext instances can't be pickled") # <<<<<<<<<<<<<< * * @cython.freelist(10) */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_PicklingError); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 330, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__55, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 330, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 330, __pyx_L1_error) /* "src/misc.pxi":329 * cdef readonly mode_t umask * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("RequestContext instances can't be pickled") * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.RequestContext.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":324 * ''' * * cdef readonly uid_t uid # <<<<<<<<<<<<<< * cdef readonly pid_t pid * cdef readonly gid_t gid */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_14RequestContext_3uid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_14RequestContext_3uid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_14RequestContext_3uid___get__(((struct __pyx_obj_6llfuse_RequestContext *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14RequestContext_3uid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_uid_t(__pyx_v_self->uid); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 324, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.RequestContext.uid.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":325 * * cdef readonly uid_t uid * cdef readonly pid_t pid # <<<<<<<<<<<<<< * cdef readonly gid_t gid * cdef readonly mode_t umask */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_14RequestContext_3pid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_14RequestContext_3pid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_14RequestContext_3pid___get__(((struct __pyx_obj_6llfuse_RequestContext *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14RequestContext_3pid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_pid_t(__pyx_v_self->pid); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 325, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.RequestContext.pid.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":326 * cdef readonly uid_t uid * cdef readonly pid_t pid * cdef readonly gid_t gid # <<<<<<<<<<<<<< * cdef readonly mode_t umask * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_14RequestContext_3gid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_14RequestContext_3gid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_14RequestContext_3gid___get__(((struct __pyx_obj_6llfuse_RequestContext *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14RequestContext_3gid___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_gid_t(__pyx_v_self->gid); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 326, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.RequestContext.gid.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":327 * cdef readonly pid_t pid * cdef readonly gid_t gid * cdef readonly mode_t umask # <<<<<<<<<<<<<< * * def __getstate__(self): */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_14RequestContext_5umask_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_14RequestContext_5umask_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_14RequestContext_5umask___get__(((struct __pyx_obj_6llfuse_RequestContext *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14RequestContext_5umask___get__(struct __pyx_obj_6llfuse_RequestContext *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_mode_t(__pyx_v_self->umask); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 327, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.RequestContext.umask.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":346 * cdef readonly object update_size * * def __cinit__(self): # <<<<<<<<<<<<<< * self.update_atime = False * self.update_mtime = False */ /* Python wrapper */ static int __pyx_pw_6llfuse_13SetattrFields_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_13SetattrFields_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0); if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) { __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;} if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__cinit__", 0))) return -1; __pyx_r = __pyx_pf_6llfuse_13SetattrFields___cinit__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_13SetattrFields___cinit__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__", 0); /* "src/misc.pxi":347 * * def __cinit__(self): * self.update_atime = False # <<<<<<<<<<<<<< * self.update_mtime = False * self.update_mode = False */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_atime); __Pyx_DECREF(__pyx_v_self->update_atime); __pyx_v_self->update_atime = Py_False; /* "src/misc.pxi":348 * def __cinit__(self): * self.update_atime = False * self.update_mtime = False # <<<<<<<<<<<<<< * self.update_mode = False * self.update_uid = False */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_mtime); __Pyx_DECREF(__pyx_v_self->update_mtime); __pyx_v_self->update_mtime = Py_False; /* "src/misc.pxi":349 * self.update_atime = False * self.update_mtime = False * self.update_mode = False # <<<<<<<<<<<<<< * self.update_uid = False * self.update_gid = False */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_mode); __Pyx_DECREF(__pyx_v_self->update_mode); __pyx_v_self->update_mode = Py_False; /* "src/misc.pxi":350 * self.update_mtime = False * self.update_mode = False * self.update_uid = False # <<<<<<<<<<<<<< * self.update_gid = False * self.update_size = False */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_uid); __Pyx_DECREF(__pyx_v_self->update_uid); __pyx_v_self->update_uid = Py_False; /* "src/misc.pxi":351 * self.update_mode = False * self.update_uid = False * self.update_gid = False # <<<<<<<<<<<<<< * self.update_size = False * */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_gid); __Pyx_DECREF(__pyx_v_self->update_gid); __pyx_v_self->update_gid = Py_False; /* "src/misc.pxi":352 * self.update_uid = False * self.update_gid = False * self.update_size = False # <<<<<<<<<<<<<< * * def __getstate__(self): */ __Pyx_INCREF(Py_False); __Pyx_GIVEREF(Py_False); __Pyx_GOTREF(__pyx_v_self->update_size); __Pyx_DECREF(__pyx_v_self->update_size); __pyx_v_self->update_size = Py_False; /* "src/misc.pxi":346 * cdef readonly object update_size * * def __cinit__(self): # <<<<<<<<<<<<<< * self.update_atime = False * self.update_mtime = False */ /* function exit code */ __pyx_r = 0; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":354 * self.update_size = False * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("SetattrFields instances can't be pickled") * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_13SetattrFields_2__getstate__[] = "SetattrFields.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_13SetattrFields_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_2__getstate__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_2__getstate__(CYTHON_UNUSED struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":355 * * def __getstate__(self): * raise PicklingError("SetattrFields instances can't be pickled") # <<<<<<<<<<<<<< * * @cython.freelist(30) */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_PicklingError); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 355, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__56, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 355, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 355, __pyx_L1_error) /* "src/misc.pxi":354 * self.update_size = False * * def __getstate__(self): # <<<<<<<<<<<<<< * raise PicklingError("SetattrFields instances can't be pickled") * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.SetattrFields.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":339 * ''' * * cdef readonly object update_atime # <<<<<<<<<<<<<< * cdef readonly object update_mtime * cdef readonly object update_mode */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_12update_atime_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_12update_atime_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_12update_atime___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_12update_atime___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_atime); __pyx_r = __pyx_v_self->update_atime; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":340 * * cdef readonly object update_atime * cdef readonly object update_mtime # <<<<<<<<<<<<<< * cdef readonly object update_mode * cdef readonly object update_uid */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_12update_mtime_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_12update_mtime_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_12update_mtime___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_12update_mtime___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_mtime); __pyx_r = __pyx_v_self->update_mtime; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":341 * cdef readonly object update_atime * cdef readonly object update_mtime * cdef readonly object update_mode # <<<<<<<<<<<<<< * cdef readonly object update_uid * cdef readonly object update_gid */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_11update_mode_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_11update_mode_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_11update_mode___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_11update_mode___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_mode); __pyx_r = __pyx_v_self->update_mode; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":342 * cdef readonly object update_mtime * cdef readonly object update_mode * cdef readonly object update_uid # <<<<<<<<<<<<<< * cdef readonly object update_gid * cdef readonly object update_size */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_10update_uid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_10update_uid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_10update_uid___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_10update_uid___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_uid); __pyx_r = __pyx_v_self->update_uid; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":343 * cdef readonly object update_mode * cdef readonly object update_uid * cdef readonly object update_gid # <<<<<<<<<<<<<< * cdef readonly object update_size * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_10update_gid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_10update_gid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_10update_gid___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_10update_gid___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_gid); __pyx_r = __pyx_v_self->update_gid; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":344 * cdef readonly object update_uid * cdef readonly object update_gid * cdef readonly object update_size # <<<<<<<<<<<<<< * * def __cinit__(self): */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13SetattrFields_11update_size_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_13SetattrFields_11update_size_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_13SetattrFields_11update_size___get__(((struct __pyx_obj_6llfuse_SetattrFields *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_13SetattrFields_11update_size___get__(struct __pyx_obj_6llfuse_SetattrFields *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_self->update_size); __pyx_r = __pyx_v_self->update_size; goto __pyx_L0; /* function exit code */ __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":371 * cdef struct_stat *attr * * def __cinit__(self): # <<<<<<<<<<<<<< * string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) * self.attr = &self.fuse_param.attr */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0); if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) { __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;} if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__cinit__", 0))) return -1; __pyx_r = __pyx_pf_6llfuse_15EntryAttributes___cinit__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes___cinit__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__", 0); /* "src/misc.pxi":372 * * def __cinit__(self): * string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) # <<<<<<<<<<<<<< * self.attr = &self.fuse_param.attr * self.fuse_param.generation = 0 */ memset((&__pyx_v_self->fuse_param), 0, (sizeof(struct fuse_entry_param))); /* "src/misc.pxi":373 * def __cinit__(self): * string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) * self.attr = &self.fuse_param.attr # <<<<<<<<<<<<<< * self.fuse_param.generation = 0 * self.fuse_param.entry_timeout = 300 */ __pyx_v_self->attr = (&__pyx_v_self->fuse_param.attr); /* "src/misc.pxi":374 * string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) * self.attr = &self.fuse_param.attr * self.fuse_param.generation = 0 # <<<<<<<<<<<<<< * self.fuse_param.entry_timeout = 300 * self.fuse_param.attr_timeout = 300 */ __pyx_v_self->fuse_param.generation = 0; /* "src/misc.pxi":375 * self.attr = &self.fuse_param.attr * self.fuse_param.generation = 0 * self.fuse_param.entry_timeout = 300 # <<<<<<<<<<<<<< * self.fuse_param.attr_timeout = 300 * */ __pyx_v_self->fuse_param.entry_timeout = 300.0; /* "src/misc.pxi":376 * self.fuse_param.generation = 0 * self.fuse_param.entry_timeout = 300 * self.fuse_param.attr_timeout = 300 # <<<<<<<<<<<<<< * * self.attr.st_mode = S_IFREG */ __pyx_v_self->fuse_param.attr_timeout = 300.0; /* "src/misc.pxi":378 * self.fuse_param.attr_timeout = 300 * * self.attr.st_mode = S_IFREG # <<<<<<<<<<<<<< * self.attr.st_blksize = 4096 * self.attr.st_nlink = 1 */ __pyx_v_self->attr->st_mode = S_IFREG; /* "src/misc.pxi":379 * * self.attr.st_mode = S_IFREG * self.attr.st_blksize = 4096 # <<<<<<<<<<<<<< * self.attr.st_nlink = 1 * */ __pyx_v_self->attr->st_blksize = 0x1000; /* "src/misc.pxi":380 * self.attr.st_mode = S_IFREG * self.attr.st_blksize = 4096 * self.attr.st_nlink = 1 # <<<<<<<<<<<<<< * * @property */ __pyx_v_self->attr->st_nlink = 1; /* "src/misc.pxi":371 * cdef struct_stat *attr * * def __cinit__(self): # <<<<<<<<<<<<<< * string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) * self.attr = &self.fuse_param.attr */ /* function exit code */ __pyx_r = 0; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":383 * * @property * def st_ino(self): # <<<<<<<<<<<<<< * return self.fuse_param.ino * @st_ino.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_ino_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_ino_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_ino___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_ino___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":384 * @property * def st_ino(self): * return self.fuse_param.ino # <<<<<<<<<<<<<< * @st_ino.setter * def st_ino(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fuse_ino_t(__pyx_v_self->fuse_param.ino); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 384, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":383 * * @property * def st_ino(self): # <<<<<<<<<<<<<< * return self.fuse_param.ino * @st_ino.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_ino.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":386 * return self.fuse_param.ino * @st_ino.setter * def st_ino(self, val): # <<<<<<<<<<<<<< * self.fuse_param.ino = val * self.attr.st_ino = val */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_6st_ino_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_6st_ino_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_ino_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_6st_ino_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fuse_ino_t __pyx_t_1; ino_t __pyx_t_2; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":387 * @st_ino.setter * def st_ino(self, val): * self.fuse_param.ino = val # <<<<<<<<<<<<<< * self.attr.st_ino = val * */ __pyx_t_1 = __Pyx_PyInt_As_fuse_ino_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fuse_ino_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 387, __pyx_L1_error) __pyx_v_self->fuse_param.ino = __pyx_t_1; /* "src/misc.pxi":388 * def st_ino(self, val): * self.fuse_param.ino = val * self.attr.st_ino = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_2 = __Pyx_PyInt_As_ino_t(__pyx_v_val); if (unlikely((__pyx_t_2 == ((ino_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 388, __pyx_L1_error) __pyx_v_self->attr->st_ino = __pyx_t_2; /* "src/misc.pxi":386 * return self.fuse_param.ino * @st_ino.setter * def st_ino(self, val): # <<<<<<<<<<<<<< * self.fuse_param.ino = val * self.attr.st_ino = val */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_ino.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":391 * * @property * def generation(self): # <<<<<<<<<<<<<< * '''The inode generation number''' * return self.fuse_param.generation */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_10generation_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_10generation_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_10generation___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_10generation___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":393 * def generation(self): * '''The inode generation number''' * return self.fuse_param.generation # <<<<<<<<<<<<<< * @generation.setter * def generation(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_unsigned_long(__pyx_v_self->fuse_param.generation); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 393, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":391 * * @property * def generation(self): # <<<<<<<<<<<<<< * '''The inode generation number''' * return self.fuse_param.generation */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.generation.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":395 * return self.fuse_param.generation * @generation.setter * def generation(self, val): # <<<<<<<<<<<<<< * self.fuse_param.generation = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_10generation_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_10generation_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_10generation_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_10generation_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations unsigned long __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":396 * @generation.setter * def generation(self, val): * self.fuse_param.generation = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_unsigned_long(__pyx_v_val); if (unlikely((__pyx_t_1 == (unsigned long)-1) && PyErr_Occurred())) __PYX_ERR(2, 396, __pyx_L1_error) __pyx_v_self->fuse_param.generation = __pyx_t_1; /* "src/misc.pxi":395 * return self.fuse_param.generation * @generation.setter * def generation(self, val): # <<<<<<<<<<<<<< * self.fuse_param.generation = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.generation.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":399 * * @property * def attr_timeout(self): # <<<<<<<<<<<<<< * '''Validity timeout for the attributes of the directory entry * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_12attr_timeout___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_12attr_timeout___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":404 * Floating point numbers may be used. Units are seconds. * ''' * return self.fuse_param.attr_timeout # <<<<<<<<<<<<<< * @attr_timeout.setter * def attr_timeout(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->fuse_param.attr_timeout); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 404, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":399 * * @property * def attr_timeout(self): # <<<<<<<<<<<<<< * '''Validity timeout for the attributes of the directory entry * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.attr_timeout.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":406 * return self.fuse_param.attr_timeout * @attr_timeout.setter * def attr_timeout(self, val): # <<<<<<<<<<<<<< * self.fuse_param.attr_timeout = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_12attr_timeout_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_12attr_timeout_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations double __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":407 * @attr_timeout.setter * def attr_timeout(self, val): * self.fuse_param.attr_timeout = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_val); if (unlikely((__pyx_t_1 == (double)-1) && PyErr_Occurred())) __PYX_ERR(2, 407, __pyx_L1_error) __pyx_v_self->fuse_param.attr_timeout = __pyx_t_1; /* "src/misc.pxi":406 * return self.fuse_param.attr_timeout * @attr_timeout.setter * def attr_timeout(self, val): # <<<<<<<<<<<<<< * self.fuse_param.attr_timeout = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.attr_timeout.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":410 * * @property * def entry_timeout(self): # <<<<<<<<<<<<<< * '''Validity timeout for the name/existence of the directory entry * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_13entry_timeout___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_13entry_timeout___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":415 * Floating point numbers may be used. Units are seconds. * ''' * return self.fuse_param.entry_timeout # <<<<<<<<<<<<<< * @entry_timeout.setter * def entry_timeout(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->fuse_param.entry_timeout); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 415, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":410 * * @property * def entry_timeout(self): # <<<<<<<<<<<<<< * '''Validity timeout for the name/existence of the directory entry * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.entry_timeout.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":417 * return self.fuse_param.entry_timeout * @entry_timeout.setter * def entry_timeout(self, val): # <<<<<<<<<<<<<< * self.fuse_param.entry_timeout = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_13entry_timeout_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_13entry_timeout_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations double __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":418 * @entry_timeout.setter * def entry_timeout(self, val): * self.fuse_param.entry_timeout = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_val); if (unlikely((__pyx_t_1 == (double)-1) && PyErr_Occurred())) __PYX_ERR(2, 418, __pyx_L1_error) __pyx_v_self->fuse_param.entry_timeout = __pyx_t_1; /* "src/misc.pxi":417 * return self.fuse_param.entry_timeout * @entry_timeout.setter * def entry_timeout(self, val): # <<<<<<<<<<<<<< * self.fuse_param.entry_timeout = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.entry_timeout.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":421 * * @property * def st_mode(self): # <<<<<<<<<<<<<< * return self.attr.st_mode * @st_mode.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_mode_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_mode_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_mode___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_mode___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":422 * @property * def st_mode(self): * return self.attr.st_mode # <<<<<<<<<<<<<< * @st_mode.setter * def st_mode(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_mode_t(__pyx_v_self->attr->st_mode); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 422, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":421 * * @property * def st_mode(self): # <<<<<<<<<<<<<< * return self.attr.st_mode * @st_mode.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_mode.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":424 * return self.attr.st_mode * @st_mode.setter * def st_mode(self, val): # <<<<<<<<<<<<<< * self.attr.st_mode = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_7st_mode_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_7st_mode_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_mode_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_7st_mode_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations mode_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":425 * @st_mode.setter * def st_mode(self, val): * self.attr.st_mode = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_mode_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((mode_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 425, __pyx_L1_error) __pyx_v_self->attr->st_mode = __pyx_t_1; /* "src/misc.pxi":424 * return self.attr.st_mode * @st_mode.setter * def st_mode(self, val): # <<<<<<<<<<<<<< * self.attr.st_mode = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_mode.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":428 * * @property * def st_nlink(self): # <<<<<<<<<<<<<< * return self.attr.st_nlink * @st_nlink.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_8st_nlink_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_8st_nlink_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_8st_nlink___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_8st_nlink___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":429 * @property * def st_nlink(self): * return self.attr.st_nlink # <<<<<<<<<<<<<< * @st_nlink.setter * def st_nlink(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_nlink_t(__pyx_v_self->attr->st_nlink); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 429, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":428 * * @property * def st_nlink(self): # <<<<<<<<<<<<<< * return self.attr.st_nlink * @st_nlink.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_nlink.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":431 * return self.attr.st_nlink * @st_nlink.setter * def st_nlink(self, val): # <<<<<<<<<<<<<< * self.attr.st_nlink = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_8st_nlink_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_8st_nlink_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_8st_nlink_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_8st_nlink_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations nlink_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":432 * @st_nlink.setter * def st_nlink(self, val): * self.attr.st_nlink = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_nlink_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((nlink_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 432, __pyx_L1_error) __pyx_v_self->attr->st_nlink = __pyx_t_1; /* "src/misc.pxi":431 * return self.attr.st_nlink * @st_nlink.setter * def st_nlink(self, val): # <<<<<<<<<<<<<< * self.attr.st_nlink = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_nlink.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":435 * * @property * def st_uid(self): # <<<<<<<<<<<<<< * return self.attr.st_uid * @st_uid.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_uid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_uid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_uid___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_uid___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":436 * @property * def st_uid(self): * return self.attr.st_uid # <<<<<<<<<<<<<< * @st_uid.setter * def st_uid(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_uid_t(__pyx_v_self->attr->st_uid); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 436, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":435 * * @property * def st_uid(self): # <<<<<<<<<<<<<< * return self.attr.st_uid * @st_uid.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_uid.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":438 * return self.attr.st_uid * @st_uid.setter * def st_uid(self, val): # <<<<<<<<<<<<<< * self.attr.st_uid = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_6st_uid_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_6st_uid_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_uid_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_6st_uid_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations uid_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":439 * @st_uid.setter * def st_uid(self, val): * self.attr.st_uid = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_uid_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((uid_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 439, __pyx_L1_error) __pyx_v_self->attr->st_uid = __pyx_t_1; /* "src/misc.pxi":438 * return self.attr.st_uid * @st_uid.setter * def st_uid(self, val): # <<<<<<<<<<<<<< * self.attr.st_uid = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_uid.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":442 * * @property * def st_gid(self): # <<<<<<<<<<<<<< * return self.attr.st_gid * @st_gid.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_gid_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_6st_gid_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_gid___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_6st_gid___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":443 * @property * def st_gid(self): * return self.attr.st_gid # <<<<<<<<<<<<<< * @st_gid.setter * def st_gid(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_gid_t(__pyx_v_self->attr->st_gid); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 443, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":442 * * @property * def st_gid(self): # <<<<<<<<<<<<<< * return self.attr.st_gid * @st_gid.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_gid.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":445 * return self.attr.st_gid * @st_gid.setter * def st_gid(self, val): # <<<<<<<<<<<<<< * self.attr.st_gid = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_6st_gid_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_6st_gid_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_6st_gid_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_6st_gid_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations gid_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":446 * @st_gid.setter * def st_gid(self, val): * self.attr.st_gid = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_gid_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((gid_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 446, __pyx_L1_error) __pyx_v_self->attr->st_gid = __pyx_t_1; /* "src/misc.pxi":445 * return self.attr.st_gid * @st_gid.setter * def st_gid(self, val): # <<<<<<<<<<<<<< * self.attr.st_gid = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_gid.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":449 * * @property * def st_rdev(self): # <<<<<<<<<<<<<< * return self.attr.st_rdev * @st_rdev.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_rdev_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_rdev_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_rdev___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_rdev___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":450 * @property * def st_rdev(self): * return self.attr.st_rdev # <<<<<<<<<<<<<< * @st_rdev.setter * def st_rdev(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_dev_t(__pyx_v_self->attr->st_rdev); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 450, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":449 * * @property * def st_rdev(self): # <<<<<<<<<<<<<< * return self.attr.st_rdev * @st_rdev.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_rdev.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":452 * return self.attr.st_rdev * @st_rdev.setter * def st_rdev(self, val): # <<<<<<<<<<<<<< * self.attr.st_rdev = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_7st_rdev_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_7st_rdev_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_rdev_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_7st_rdev_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations dev_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":453 * @st_rdev.setter * def st_rdev(self, val): * self.attr.st_rdev = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_dev_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((dev_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 453, __pyx_L1_error) __pyx_v_self->attr->st_rdev = __pyx_t_1; /* "src/misc.pxi":452 * return self.attr.st_rdev * @st_rdev.setter * def st_rdev(self, val): # <<<<<<<<<<<<<< * self.attr.st_rdev = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_rdev.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":456 * * @property * def st_size(self): # <<<<<<<<<<<<<< * return self.attr.st_size * @st_size.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_size_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_7st_size_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_size___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_7st_size___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":457 * @property * def st_size(self): * return self.attr.st_size # <<<<<<<<<<<<<< * @st_size.setter * def st_size(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_off_t(__pyx_v_self->attr->st_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 457, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":456 * * @property * def st_size(self): # <<<<<<<<<<<<<< * return self.attr.st_size * @st_size.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_size.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":459 * return self.attr.st_size * @st_size.setter * def st_size(self, val): # <<<<<<<<<<<<<< * self.attr.st_size = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_7st_size_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_7st_size_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_7st_size_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_7st_size_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations off_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":460 * @st_size.setter * def st_size(self, val): * self.attr.st_size = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_off_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((off_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 460, __pyx_L1_error) __pyx_v_self->attr->st_size = __pyx_t_1; /* "src/misc.pxi":459 * return self.attr.st_size * @st_size.setter * def st_size(self, val): # <<<<<<<<<<<<<< * self.attr.st_size = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_size.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":463 * * @property * def st_blocks(self): # <<<<<<<<<<<<<< * return self.attr.st_blocks * @st_blocks.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_9st_blocks_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_9st_blocks_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_9st_blocks___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_9st_blocks___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":464 * @property * def st_blocks(self): * return self.attr.st_blocks # <<<<<<<<<<<<<< * @st_blocks.setter * def st_blocks(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_blkcnt_t(__pyx_v_self->attr->st_blocks); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 464, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":463 * * @property * def st_blocks(self): # <<<<<<<<<<<<<< * return self.attr.st_blocks * @st_blocks.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_blocks.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":466 * return self.attr.st_blocks * @st_blocks.setter * def st_blocks(self, val): # <<<<<<<<<<<<<< * self.attr.st_blocks = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_9st_blocks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_9st_blocks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_9st_blocks_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_9st_blocks_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations blkcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":467 * @st_blocks.setter * def st_blocks(self, val): * self.attr.st_blocks = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_blkcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((blkcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 467, __pyx_L1_error) __pyx_v_self->attr->st_blocks = __pyx_t_1; /* "src/misc.pxi":466 * return self.attr.st_blocks * @st_blocks.setter * def st_blocks(self, val): # <<<<<<<<<<<<<< * self.attr.st_blocks = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_blocks.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":470 * * @property * def st_blksize(self): # <<<<<<<<<<<<<< * return self.attr.st_blksize * @st_blksize.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_10st_blksize_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_10st_blksize_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_10st_blksize___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_10st_blksize___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":471 * @property * def st_blksize(self): * return self.attr.st_blksize # <<<<<<<<<<<<<< * @st_blksize.setter * def st_blksize(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_blksize_t(__pyx_v_self->attr->st_blksize); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 471, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":470 * * @property * def st_blksize(self): # <<<<<<<<<<<<<< * return self.attr.st_blksize * @st_blksize.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_blksize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":473 * return self.attr.st_blksize * @st_blksize.setter * def st_blksize(self, val): # <<<<<<<<<<<<<< * self.attr.st_blksize = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_10st_blksize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_10st_blksize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_10st_blksize_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_10st_blksize_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations blksize_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":474 * @st_blksize.setter * def st_blksize(self, val): * self.attr.st_blksize = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_blksize_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((blksize_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 474, __pyx_L1_error) __pyx_v_self->attr->st_blksize = __pyx_t_1; /* "src/misc.pxi":473 * return self.attr.st_blksize * @st_blksize.setter * def st_blksize(self, val): # <<<<<<<<<<<<<< * self.attr.st_blksize = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.EntryAttributes.st_blksize.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":477 * * @property * def st_atime_ns(self): # <<<<<<<<<<<<<< * '''Time of last access in (integer) nanoseconds''' * return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":479 * def st_atime_ns(self): * '''Time of last access in (integer) nanoseconds''' * return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) # <<<<<<<<<<<<<< * @st_atime_ns.setter * def st_atime_ns(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_time_t(__pyx_v_self->attr->st_atime); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)(&PyInt_Type)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = PyNumber_Multiply(__pyx_t_1, __pyx_int_1000000000); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyInt_From_long(GET_ATIME_NS(__pyx_v_self->attr)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; /* "src/misc.pxi":477 * * @property * def st_atime_ns(self): # <<<<<<<<<<<<<< * '''Time of last access in (integer) nanoseconds''' * return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.EntryAttributes.st_atime_ns.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":481 * return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) * @st_atime_ns.setter * def st_atime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_atime = val / 10**9 * SET_ATIME_NS(self.attr, val % 10**9) */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_11st_atime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; time_t __pyx_t_2; long __pyx_t_3; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":482 * @st_atime_ns.setter * def st_atime_ns(self, val): * self.attr.st_atime = val / 10**9 # <<<<<<<<<<<<<< * SET_ATIME_NS(self.attr, val % 10**9) * */ __pyx_t_1 = __Pyx_PyInt_TrueDivideObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 482, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_time_t(__pyx_t_1); if (unlikely((__pyx_t_2 == ((time_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 482, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->attr->st_atime = __pyx_t_2; /* "src/misc.pxi":483 * def st_atime_ns(self, val): * self.attr.st_atime = val / 10**9 * SET_ATIME_NS(self.attr, val % 10**9) # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_RemainderObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = __Pyx_PyInt_As_long(__pyx_t_1); if (unlikely((__pyx_t_3 == (long)-1) && PyErr_Occurred())) __PYX_ERR(2, 483, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; SET_ATIME_NS(__pyx_v_self->attr, __pyx_t_3); /* "src/misc.pxi":481 * return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) * @st_atime_ns.setter * def st_atime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_atime = val / 10**9 * SET_ATIME_NS(self.attr, val % 10**9) */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_atime_ns.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":486 * * @property * def st_mtime_ns(self): # <<<<<<<<<<<<<< * '''Time of last modification in (integer) nanoseconds''' * return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":488 * def st_mtime_ns(self): * '''Time of last modification in (integer) nanoseconds''' * return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) # <<<<<<<<<<<<<< * @st_mtime_ns.setter * def st_mtime_ns(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_time_t(__pyx_v_self->attr->st_mtime); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)(&PyInt_Type)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = PyNumber_Multiply(__pyx_t_1, __pyx_int_1000000000); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyInt_From_long(GET_MTIME_NS(__pyx_v_self->attr)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 488, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; /* "src/misc.pxi":486 * * @property * def st_mtime_ns(self): # <<<<<<<<<<<<<< * '''Time of last modification in (integer) nanoseconds''' * return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.EntryAttributes.st_mtime_ns.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":490 * return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) * @st_mtime_ns.setter * def st_mtime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_mtime = val / 10**9 * SET_MTIME_NS(self.attr, val % 10**9) */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_11st_mtime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; time_t __pyx_t_2; long __pyx_t_3; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":491 * @st_mtime_ns.setter * def st_mtime_ns(self, val): * self.attr.st_mtime = val / 10**9 # <<<<<<<<<<<<<< * SET_MTIME_NS(self.attr, val % 10**9) * */ __pyx_t_1 = __Pyx_PyInt_TrueDivideObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_time_t(__pyx_t_1); if (unlikely((__pyx_t_2 == ((time_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 491, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->attr->st_mtime = __pyx_t_2; /* "src/misc.pxi":492 * def st_mtime_ns(self, val): * self.attr.st_mtime = val / 10**9 * SET_MTIME_NS(self.attr, val % 10**9) # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_RemainderObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 492, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = __Pyx_PyInt_As_long(__pyx_t_1); if (unlikely((__pyx_t_3 == (long)-1) && PyErr_Occurred())) __PYX_ERR(2, 492, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; SET_MTIME_NS(__pyx_v_self->attr, __pyx_t_3); /* "src/misc.pxi":490 * return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) * @st_mtime_ns.setter * def st_mtime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_mtime = val / 10**9 * SET_MTIME_NS(self.attr, val % 10**9) */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_mtime_ns.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":495 * * @property * def st_ctime_ns(self): # <<<<<<<<<<<<<< * '''Time of last inode modification in (integer) nanoseconds''' * return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":497 * def st_ctime_ns(self): * '''Time of last inode modification in (integer) nanoseconds''' * return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) # <<<<<<<<<<<<<< * @st_ctime_ns.setter * def st_ctime_ns(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_time_t(__pyx_v_self->attr->st_ctime); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)(&PyInt_Type)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = PyNumber_Multiply(__pyx_t_1, __pyx_int_1000000000); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyInt_From_long(GET_CTIME_NS(__pyx_v_self->attr)); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyNumber_Add(__pyx_t_2, __pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 497, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_r = __pyx_t_3; __pyx_t_3 = 0; goto __pyx_L0; /* "src/misc.pxi":495 * * @property * def st_ctime_ns(self): # <<<<<<<<<<<<<< * '''Time of last inode modification in (integer) nanoseconds''' * return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.EntryAttributes.st_ctime_ns.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":499 * return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) * @st_ctime_ns.setter * def st_ctime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_ctime = val / 10**9 * SET_CTIME_NS(self.attr, val % 10**9) */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_11st_ctime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; time_t __pyx_t_2; long __pyx_t_3; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":500 * @st_ctime_ns.setter * def st_ctime_ns(self, val): * self.attr.st_ctime = val / 10**9 # <<<<<<<<<<<<<< * SET_CTIME_NS(self.attr, val % 10**9) * */ __pyx_t_1 = __Pyx_PyInt_TrueDivideObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 500, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_time_t(__pyx_t_1); if (unlikely((__pyx_t_2 == ((time_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 500, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_v_self->attr->st_ctime = __pyx_t_2; /* "src/misc.pxi":501 * def st_ctime_ns(self, val): * self.attr.st_ctime = val / 10**9 * SET_CTIME_NS(self.attr, val % 10**9) # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_RemainderObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 501, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = __Pyx_PyInt_As_long(__pyx_t_1); if (unlikely((__pyx_t_3 == (long)-1) && PyErr_Occurred())) __PYX_ERR(2, 501, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; SET_CTIME_NS(__pyx_v_self->attr, __pyx_t_3); /* "src/misc.pxi":499 * return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) * @st_ctime_ns.setter * def st_ctime_ns(self, val): # <<<<<<<<<<<<<< * self.attr.st_ctime = val / 10**9 * SET_CTIME_NS(self.attr, val % 10**9) */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_ctime_ns.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":504 * * @property * def st_birthtime_ns(self): # <<<<<<<<<<<<<< * '''Time of inode creation in (integer) nanoseconds. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns___get__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns___get__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":512 * # Use C macro to prevent compiler error on Linux * # (where st_birthtime does not exist) * return int(GET_BIRTHTIME(self.attr) * 10**9 # <<<<<<<<<<<<<< * + GET_BIRTHTIME_NS(self.attr)) * */ __Pyx_XDECREF(__pyx_r); /* "src/misc.pxi":513 * # (where st_birthtime does not exist) * return int(GET_BIRTHTIME(self.attr) * 10**9 * + GET_BIRTHTIME_NS(self.attr)) # <<<<<<<<<<<<<< * * @st_birthtime_ns.setter */ __pyx_t_1 = __Pyx_PyInt_From_long(((GET_BIRTHTIME(__pyx_v_self->attr) * 0x3B9ACA00) + GET_BIRTHTIME_NS(__pyx_v_self->attr))); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 513, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); /* "src/misc.pxi":512 * # Use C macro to prevent compiler error on Linux * # (where st_birthtime does not exist) * return int(GET_BIRTHTIME(self.attr) * 10**9 # <<<<<<<<<<<<<< * + GET_BIRTHTIME_NS(self.attr)) * */ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)(&PyInt_Type)), __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 512, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":504 * * @property * def st_birthtime_ns(self): # <<<<<<<<<<<<<< * '''Time of inode creation in (integer) nanoseconds. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.EntryAttributes.st_birthtime_ns.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":516 * * @st_birthtime_ns.setter * def st_birthtime_ns(self, val): # <<<<<<<<<<<<<< * # Use C macro to prevent compiler error on Linux * # (where st_birthtime does not exist) */ /* Python wrapper */ static int __pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns_2__set__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_15EntryAttributes_15st_birthtime_ns_2__set__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; long __pyx_t_2; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":519 * # Use C macro to prevent compiler error on Linux * # (where st_birthtime does not exist) * SET_BIRTHTIME(self.attr, val / 10**9) # <<<<<<<<<<<<<< * SET_BIRTHTIME_NS(self.attr, val % 10**9) * */ __pyx_t_1 = __Pyx_PyInt_TrueDivideObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 519, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_long(__pyx_t_1); if (unlikely((__pyx_t_2 == (long)-1) && PyErr_Occurred())) __PYX_ERR(2, 519, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; SET_BIRTHTIME(__pyx_v_self->attr, __pyx_t_2); /* "src/misc.pxi":520 * # (where st_birthtime does not exist) * SET_BIRTHTIME(self.attr, val / 10**9) * SET_BIRTHTIME_NS(self.attr, val % 10**9) # <<<<<<<<<<<<<< * * # Pickling and copy support */ __pyx_t_1 = __Pyx_PyInt_RemainderObjC(__pyx_v_val, __pyx_int_1000000000, 0x3B9ACA00, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 520, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyInt_As_long(__pyx_t_1); if (unlikely((__pyx_t_2 == (long)-1) && PyErr_Occurred())) __PYX_ERR(2, 520, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; SET_BIRTHTIME_NS(__pyx_v_self->attr, __pyx_t_2); /* "src/misc.pxi":516 * * @st_birthtime_ns.setter * def st_birthtime_ns(self, val): # <<<<<<<<<<<<<< * # Use C macro to prevent compiler error on Linux * # (where st_birthtime does not exist) */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.EntryAttributes.st_birthtime_ns.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":523 * * # Pickling and copy support * def __getstate__(self): # <<<<<<<<<<<<<< * state = dict() * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_15EntryAttributes_2__getstate__[] = "EntryAttributes.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_15EntryAttributes_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_2__getstate__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_2__getstate__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self) { PyObject *__pyx_v_state = NULL; PyObject *__pyx_v_k = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":524 * # Pickling and copy support * def __getstate__(self): * state = dict() # <<<<<<<<<<<<<< * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', * 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', */ __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 524, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_state = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":525 * def __getstate__(self): * state = dict() * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', # <<<<<<<<<<<<<< * 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', * 'st_size', 'st_blksize', 'st_blocks', 'st_atime_ns', */ __pyx_t_1 = __pyx_tuple__57; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= 16) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 525, __pyx_L1_error) #else __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_k, ((PyObject*)__pyx_t_3)); __pyx_t_3 = 0; /* "src/misc.pxi":529 * 'st_size', 'st_blksize', 'st_blocks', 'st_atime_ns', * 'st_ctime_ns', 'st_mtime_ns', 'st_birthtime_ns'): * state[k] = getattr(self, k) # <<<<<<<<<<<<<< * return state * */ __pyx_t_3 = __Pyx_GetAttr(((PyObject *)__pyx_v_self), __pyx_v_k); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 529, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); if (unlikely(PyDict_SetItem(__pyx_v_state, __pyx_v_k, __pyx_t_3) < 0)) __PYX_ERR(2, 529, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/misc.pxi":525 * def __getstate__(self): * state = dict() * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', # <<<<<<<<<<<<<< * 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', * 'st_size', 'st_blksize', 'st_blocks', 'st_atime_ns', */ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":530 * 'st_ctime_ns', 'st_mtime_ns', 'st_birthtime_ns'): * state[k] = getattr(self, k) * return state # <<<<<<<<<<<<<< * * def __setstate__(self, state): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_state); __pyx_r = __pyx_v_state; goto __pyx_L0; /* "src/misc.pxi":523 * * # Pickling and copy support * def __getstate__(self): # <<<<<<<<<<<<<< * state = dict() * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.EntryAttributes.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_state); __Pyx_XDECREF(__pyx_v_k); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":532 * return state * * def __setstate__(self, state): # <<<<<<<<<<<<<< * for (k,v) in state.items(): * setattr(self, k, v) */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15EntryAttributes_5__setstate__(PyObject *__pyx_v_self, PyObject *__pyx_v_state); /*proto*/ static char __pyx_doc_6llfuse_15EntryAttributes_4__setstate__[] = "EntryAttributes.__setstate__(self, state)"; static PyObject *__pyx_pw_6llfuse_15EntryAttributes_5__setstate__(PyObject *__pyx_v_self, PyObject *__pyx_v_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_15EntryAttributes_4__setstate__(((struct __pyx_obj_6llfuse_EntryAttributes *)__pyx_v_self), ((PyObject *)__pyx_v_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_15EntryAttributes_4__setstate__(struct __pyx_obj_6llfuse_EntryAttributes *__pyx_v_self, PyObject *__pyx_v_state) { PyObject *__pyx_v_k = NULL; PyObject *__pyx_v_v = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; Py_ssize_t __pyx_t_3; int __pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; int __pyx_t_8; __Pyx_RefNannySetupContext("__setstate__", 0); /* "src/misc.pxi":533 * * def __setstate__(self, state): * for (k,v) in state.items(): # <<<<<<<<<<<<<< * setattr(self, k, v) * */ __pyx_t_2 = 0; if (unlikely(__pyx_v_state == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "items"); __PYX_ERR(2, 533, __pyx_L1_error) } __pyx_t_5 = __Pyx_dict_iterator(__pyx_v_state, 0, __pyx_n_s_items, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = __pyx_t_5; __pyx_t_5 = 0; while (1) { __pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_3, &__pyx_t_2, &__pyx_t_5, &__pyx_t_6, NULL, __pyx_t_4); if (unlikely(__pyx_t_7 == 0)) break; if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(2, 533, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_6); __Pyx_XDECREF_SET(__pyx_v_k, __pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF_SET(__pyx_v_v, __pyx_t_6); __pyx_t_6 = 0; /* "src/misc.pxi":534 * def __setstate__(self, state): * for (k,v) in state.items(): * setattr(self, k, v) # <<<<<<<<<<<<<< * * */ __pyx_t_8 = PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_v_k, __pyx_v_v); if (unlikely(__pyx_t_8 == -1)) __PYX_ERR(2, 534, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":532 * return state * * def __setstate__(self, state): # <<<<<<<<<<<<<< * for (k,v) in state.items(): * setattr(self, k, v) */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("llfuse.EntryAttributes.__setstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_k); __Pyx_XDECREF(__pyx_v_v); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":547 * cdef statvfs stat * * def __cinit__(self): # <<<<<<<<<<<<<< * string.memset(&self.stat, 0, sizeof(statvfs)) * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0); if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) { __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args)); return -1;} if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "__cinit__", 0))) return -1; __pyx_r = __pyx_pf_6llfuse_11StatvfsData___cinit__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData___cinit__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__", 0); /* "src/misc.pxi":548 * * def __cinit__(self): * string.memset(&self.stat, 0, sizeof(statvfs)) # <<<<<<<<<<<<<< * * @property */ memset((&__pyx_v_self->stat), 0, (sizeof(struct statvfs))); /* "src/misc.pxi":547 * cdef statvfs stat * * def __cinit__(self): # <<<<<<<<<<<<<< * string.memset(&self.stat, 0, sizeof(statvfs)) * */ /* function exit code */ __pyx_r = 0; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":551 * * @property * def f_bsize(self): # <<<<<<<<<<<<<< * return self.stat.f_bsize * @f_bsize.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_bsize_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_bsize_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_bsize___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_bsize___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":552 * @property * def f_bsize(self): * return self.stat.f_bsize # <<<<<<<<<<<<<< * @f_bsize.setter * def f_bsize(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_unsigned_long(__pyx_v_self->stat.f_bsize); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 552, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":551 * * @property * def f_bsize(self): # <<<<<<<<<<<<<< * return self.stat.f_bsize * @f_bsize.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_bsize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":554 * return self.stat.f_bsize * @f_bsize.setter * def f_bsize(self, val): # <<<<<<<<<<<<<< * self.stat.f_bsize = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_7f_bsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_7f_bsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_bsize_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_7f_bsize_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations unsigned long __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":555 * @f_bsize.setter * def f_bsize(self, val): * self.stat.f_bsize = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_unsigned_long(__pyx_v_val); if (unlikely((__pyx_t_1 == (unsigned long)-1) && PyErr_Occurred())) __PYX_ERR(2, 555, __pyx_L1_error) __pyx_v_self->stat.f_bsize = __pyx_t_1; /* "src/misc.pxi":554 * return self.stat.f_bsize * @f_bsize.setter * def f_bsize(self, val): # <<<<<<<<<<<<<< * self.stat.f_bsize = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_bsize.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":558 * * @property * def f_frsize(self): # <<<<<<<<<<<<<< * return self.stat.f_frsize * @f_frsize.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_frsize_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_frsize_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_frsize___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_frsize___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":559 * @property * def f_frsize(self): * return self.stat.f_frsize # <<<<<<<<<<<<<< * @f_frsize.setter * def f_frsize(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_unsigned_long(__pyx_v_self->stat.f_frsize); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 559, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":558 * * @property * def f_frsize(self): # <<<<<<<<<<<<<< * return self.stat.f_frsize * @f_frsize.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_frsize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":561 * return self.stat.f_frsize * @f_frsize.setter * def f_frsize(self, val): # <<<<<<<<<<<<<< * self.stat.f_frsize = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_8f_frsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_8f_frsize_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_frsize_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_8f_frsize_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations unsigned long __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":562 * @f_frsize.setter * def f_frsize(self, val): * self.stat.f_frsize = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_unsigned_long(__pyx_v_val); if (unlikely((__pyx_t_1 == (unsigned long)-1) && PyErr_Occurred())) __PYX_ERR(2, 562, __pyx_L1_error) __pyx_v_self->stat.f_frsize = __pyx_t_1; /* "src/misc.pxi":561 * return self.stat.f_frsize * @f_frsize.setter * def f_frsize(self, val): # <<<<<<<<<<<<<< * self.stat.f_frsize = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_frsize.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":565 * * @property * def f_blocks(self): # <<<<<<<<<<<<<< * return self.stat.f_blocks * @f_blocks.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_blocks_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_blocks_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_blocks___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_blocks___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":566 * @property * def f_blocks(self): * return self.stat.f_blocks # <<<<<<<<<<<<<< * @f_blocks.setter * def f_blocks(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsblkcnt_t(__pyx_v_self->stat.f_blocks); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 566, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":565 * * @property * def f_blocks(self): # <<<<<<<<<<<<<< * return self.stat.f_blocks * @f_blocks.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_blocks.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":568 * return self.stat.f_blocks * @f_blocks.setter * def f_blocks(self, val): # <<<<<<<<<<<<<< * self.stat.f_blocks = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_8f_blocks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_8f_blocks_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_blocks_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_8f_blocks_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsblkcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":569 * @f_blocks.setter * def f_blocks(self, val): * self.stat.f_blocks = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsblkcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsblkcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 569, __pyx_L1_error) __pyx_v_self->stat.f_blocks = __pyx_t_1; /* "src/misc.pxi":568 * return self.stat.f_blocks * @f_blocks.setter * def f_blocks(self, val): # <<<<<<<<<<<<<< * self.stat.f_blocks = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_blocks.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":572 * * @property * def f_bfree(self): # <<<<<<<<<<<<<< * return self.stat.f_bfree * @f_bfree.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_bfree_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_bfree_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_bfree___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_bfree___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":573 * @property * def f_bfree(self): * return self.stat.f_bfree # <<<<<<<<<<<<<< * @f_bfree.setter * def f_bfree(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsblkcnt_t(__pyx_v_self->stat.f_bfree); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":572 * * @property * def f_bfree(self): # <<<<<<<<<<<<<< * return self.stat.f_bfree * @f_bfree.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_bfree.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":575 * return self.stat.f_bfree * @f_bfree.setter * def f_bfree(self, val): # <<<<<<<<<<<<<< * self.stat.f_bfree = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_7f_bfree_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_7f_bfree_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_bfree_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_7f_bfree_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsblkcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":576 * @f_bfree.setter * def f_bfree(self, val): * self.stat.f_bfree = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsblkcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsblkcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 576, __pyx_L1_error) __pyx_v_self->stat.f_bfree = __pyx_t_1; /* "src/misc.pxi":575 * return self.stat.f_bfree * @f_bfree.setter * def f_bfree(self, val): # <<<<<<<<<<<<<< * self.stat.f_bfree = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_bfree.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":579 * * @property * def f_bavail(self): # <<<<<<<<<<<<<< * return self.stat.f_bavail * @f_bavail.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_bavail_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_bavail_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_bavail___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_bavail___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":580 * @property * def f_bavail(self): * return self.stat.f_bavail # <<<<<<<<<<<<<< * @f_bavail.setter * def f_bavail(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsblkcnt_t(__pyx_v_self->stat.f_bavail); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 580, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":579 * * @property * def f_bavail(self): # <<<<<<<<<<<<<< * return self.stat.f_bavail * @f_bavail.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_bavail.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":582 * return self.stat.f_bavail * @f_bavail.setter * def f_bavail(self, val): # <<<<<<<<<<<<<< * self.stat.f_bavail = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_8f_bavail_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_8f_bavail_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_bavail_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_8f_bavail_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsblkcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":583 * @f_bavail.setter * def f_bavail(self, val): * self.stat.f_bavail = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsblkcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsblkcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 583, __pyx_L1_error) __pyx_v_self->stat.f_bavail = __pyx_t_1; /* "src/misc.pxi":582 * return self.stat.f_bavail * @f_bavail.setter * def f_bavail(self, val): # <<<<<<<<<<<<<< * self.stat.f_bavail = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_bavail.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":586 * * @property * def f_files(self): # <<<<<<<<<<<<<< * return self.stat.f_files * @f_files.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_files_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_files_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_files___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_files___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":587 * @property * def f_files(self): * return self.stat.f_files # <<<<<<<<<<<<<< * @f_files.setter * def f_files(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsfilcnt_t(__pyx_v_self->stat.f_files); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 587, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":586 * * @property * def f_files(self): # <<<<<<<<<<<<<< * return self.stat.f_files * @f_files.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_files.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":589 * return self.stat.f_files * @f_files.setter * def f_files(self, val): # <<<<<<<<<<<<<< * self.stat.f_files = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_7f_files_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_7f_files_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_files_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_7f_files_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsfilcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":590 * @f_files.setter * def f_files(self, val): * self.stat.f_files = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsfilcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsfilcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 590, __pyx_L1_error) __pyx_v_self->stat.f_files = __pyx_t_1; /* "src/misc.pxi":589 * return self.stat.f_files * @f_files.setter * def f_files(self, val): # <<<<<<<<<<<<<< * self.stat.f_files = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_files.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":593 * * @property * def f_ffree(self): # <<<<<<<<<<<<<< * return self.stat.f_ffree * @f_ffree.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_ffree_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_7f_ffree_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_ffree___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_7f_ffree___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":594 * @property * def f_ffree(self): * return self.stat.f_ffree # <<<<<<<<<<<<<< * @f_ffree.setter * def f_ffree(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsfilcnt_t(__pyx_v_self->stat.f_ffree); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 594, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":593 * * @property * def f_ffree(self): # <<<<<<<<<<<<<< * return self.stat.f_ffree * @f_ffree.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_ffree.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":596 * return self.stat.f_ffree * @f_ffree.setter * def f_ffree(self, val): # <<<<<<<<<<<<<< * self.stat.f_ffree = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_7f_ffree_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_7f_ffree_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_7f_ffree_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_7f_ffree_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsfilcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":597 * @f_ffree.setter * def f_ffree(self, val): * self.stat.f_ffree = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsfilcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsfilcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 597, __pyx_L1_error) __pyx_v_self->stat.f_ffree = __pyx_t_1; /* "src/misc.pxi":596 * return self.stat.f_ffree * @f_ffree.setter * def f_ffree(self, val): # <<<<<<<<<<<<<< * self.stat.f_ffree = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_ffree.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":600 * * @property * def f_favail(self): # <<<<<<<<<<<<<< * return self.stat.f_favail * @f_favail.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_favail_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_8f_favail_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_favail___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_8f_favail___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":601 * @property * def f_favail(self): * return self.stat.f_favail # <<<<<<<<<<<<<< * @f_favail.setter * def f_favail(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_fsfilcnt_t(__pyx_v_self->stat.f_favail); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 601, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":600 * * @property * def f_favail(self): # <<<<<<<<<<<<<< * return self.stat.f_favail * @f_favail.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_favail.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":603 * return self.stat.f_favail * @f_favail.setter * def f_favail(self, val): # <<<<<<<<<<<<<< * self.stat.f_favail = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_8f_favail_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_8f_favail_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_8f_favail_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_8f_favail_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations fsfilcnt_t __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":604 * @f_favail.setter * def f_favail(self, val): * self.stat.f_favail = val # <<<<<<<<<<<<<< * * @property */ __pyx_t_1 = __Pyx_PyInt_As_fsfilcnt_t(__pyx_v_val); if (unlikely((__pyx_t_1 == ((fsfilcnt_t)-1)) && PyErr_Occurred())) __PYX_ERR(2, 604, __pyx_L1_error) __pyx_v_self->stat.f_favail = __pyx_t_1; /* "src/misc.pxi":603 * return self.stat.f_favail * @f_favail.setter * def f_favail(self, val): # <<<<<<<<<<<<<< * self.stat.f_favail = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_favail.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":607 * * @property * def f_namemax(self): # <<<<<<<<<<<<<< * return self.stat.f_namemax * @f_namemax.setter */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_9f_namemax_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_11StatvfsData_9f_namemax_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_9f_namemax___get__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_9f_namemax___get__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":608 * @property * def f_namemax(self): * return self.stat.f_namemax # <<<<<<<<<<<<<< * @f_namemax.setter * def f_namemax(self, val): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_unsigned_long(__pyx_v_self->stat.f_namemax); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 608, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":607 * * @property * def f_namemax(self): # <<<<<<<<<<<<<< * return self.stat.f_namemax * @f_namemax.setter */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.StatvfsData.f_namemax.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":610 * return self.stat.f_namemax * @f_namemax.setter * def f_namemax(self, val): # <<<<<<<<<<<<<< * self.stat.f_namemax = val * */ /* Python wrapper */ static int __pyx_pw_6llfuse_11StatvfsData_9f_namemax_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val); /*proto*/ static int __pyx_pw_6llfuse_11StatvfsData_9f_namemax_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__set__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_9f_namemax_2__set__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_val)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_11StatvfsData_9f_namemax_2__set__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_val) { int __pyx_r; __Pyx_RefNannyDeclarations unsigned long __pyx_t_1; __Pyx_RefNannySetupContext("__set__", 0); /* "src/misc.pxi":611 * @f_namemax.setter * def f_namemax(self, val): * self.stat.f_namemax = val # <<<<<<<<<<<<<< * * # Pickling and copy support */ __pyx_t_1 = __Pyx_PyInt_As_unsigned_long(__pyx_v_val); if (unlikely((__pyx_t_1 == (unsigned long)-1) && PyErr_Occurred())) __PYX_ERR(2, 611, __pyx_L1_error) __pyx_v_self->stat.f_namemax = __pyx_t_1; /* "src/misc.pxi":610 * return self.stat.f_namemax * @f_namemax.setter * def f_namemax(self, val): # <<<<<<<<<<<<<< * self.stat.f_namemax = val * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.StatvfsData.f_namemax.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":614 * * # Pickling and copy support * def __getstate__(self): # <<<<<<<<<<<<<< * state = dict() * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_11StatvfsData_2__getstate__[] = "StatvfsData.__getstate__(self)"; static PyObject *__pyx_pw_6llfuse_11StatvfsData_3__getstate__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__getstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_2__getstate__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_2__getstate__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self) { PyObject *__pyx_v_state = NULL; PyObject *__pyx_v_k = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; PyObject *__pyx_t_3 = NULL; __Pyx_RefNannySetupContext("__getstate__", 0); /* "src/misc.pxi":615 * # Pickling and copy support * def __getstate__(self): * state = dict() # <<<<<<<<<<<<<< * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', * 'f_bavail', 'f_files', 'f_ffree', 'f_favail', */ __pyx_t_1 = PyDict_New(); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 615, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_state = ((PyObject*)__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":616 * def __getstate__(self): * state = dict() * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', # <<<<<<<<<<<<<< * 'f_bavail', 'f_files', 'f_ffree', 'f_favail', * 'f_namemax'): */ __pyx_t_1 = __pyx_tuple__58; __Pyx_INCREF(__pyx_t_1); __pyx_t_2 = 0; for (;;) { if (__pyx_t_2 >= 9) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_2); __Pyx_INCREF(__pyx_t_3); __pyx_t_2++; if (unlikely(0 < 0)) __PYX_ERR(2, 616, __pyx_L1_error) #else __pyx_t_3 = PySequence_ITEM(__pyx_t_1, __pyx_t_2); __pyx_t_2++; if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 616, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); #endif __Pyx_XDECREF_SET(__pyx_v_k, ((PyObject*)__pyx_t_3)); __pyx_t_3 = 0; /* "src/misc.pxi":619 * 'f_bavail', 'f_files', 'f_ffree', 'f_favail', * 'f_namemax'): * state[k] = getattr(self, k) # <<<<<<<<<<<<<< * return state * */ __pyx_t_3 = __Pyx_GetAttr(((PyObject *)__pyx_v_self), __pyx_v_k); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 619, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); if (unlikely(PyDict_SetItem(__pyx_v_state, __pyx_v_k, __pyx_t_3) < 0)) __PYX_ERR(2, 619, __pyx_L1_error) __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/misc.pxi":616 * def __getstate__(self): * state = dict() * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', # <<<<<<<<<<<<<< * 'f_bavail', 'f_files', 'f_ffree', 'f_favail', * 'f_namemax'): */ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":620 * 'f_namemax'): * state[k] = getattr(self, k) * return state # <<<<<<<<<<<<<< * * def __setstate__(self, state): */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_state); __pyx_r = __pyx_v_state; goto __pyx_L0; /* "src/misc.pxi":614 * * # Pickling and copy support * def __getstate__(self): # <<<<<<<<<<<<<< * state = dict() * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __Pyx_AddTraceback("llfuse.StatvfsData.__getstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_state); __Pyx_XDECREF(__pyx_v_k); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":622 * return state * * def __setstate__(self, state): # <<<<<<<<<<<<<< * for (k,v) in state.items(): * setattr(self, k, v) */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11StatvfsData_5__setstate__(PyObject *__pyx_v_self, PyObject *__pyx_v_state); /*proto*/ static char __pyx_doc_6llfuse_11StatvfsData_4__setstate__[] = "StatvfsData.__setstate__(self, state)"; static PyObject *__pyx_pw_6llfuse_11StatvfsData_5__setstate__(PyObject *__pyx_v_self, PyObject *__pyx_v_state) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__setstate__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_11StatvfsData_4__setstate__(((struct __pyx_obj_6llfuse_StatvfsData *)__pyx_v_self), ((PyObject *)__pyx_v_state)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_11StatvfsData_4__setstate__(struct __pyx_obj_6llfuse_StatvfsData *__pyx_v_self, PyObject *__pyx_v_state) { PyObject *__pyx_v_k = NULL; PyObject *__pyx_v_v = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; Py_ssize_t __pyx_t_2; Py_ssize_t __pyx_t_3; int __pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; int __pyx_t_8; __Pyx_RefNannySetupContext("__setstate__", 0); /* "src/misc.pxi":623 * * def __setstate__(self, state): * for (k,v) in state.items(): # <<<<<<<<<<<<<< * setattr(self, k, v) * */ __pyx_t_2 = 0; if (unlikely(__pyx_v_state == Py_None)) { PyErr_Format(PyExc_AttributeError, "'NoneType' object has no attribute '%s'", "items"); __PYX_ERR(2, 623, __pyx_L1_error) } __pyx_t_5 = __Pyx_dict_iterator(__pyx_v_state, 0, __pyx_n_s_items, (&__pyx_t_3), (&__pyx_t_4)); if (unlikely(!__pyx_t_5)) __PYX_ERR(2, 623, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = __pyx_t_5; __pyx_t_5 = 0; while (1) { __pyx_t_7 = __Pyx_dict_iter_next(__pyx_t_1, __pyx_t_3, &__pyx_t_2, &__pyx_t_5, &__pyx_t_6, NULL, __pyx_t_4); if (unlikely(__pyx_t_7 == 0)) break; if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(2, 623, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_6); __Pyx_XDECREF_SET(__pyx_v_k, __pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF_SET(__pyx_v_v, __pyx_t_6); __pyx_t_6 = 0; /* "src/misc.pxi":624 * def __setstate__(self, state): * for (k,v) in state.items(): * setattr(self, k, v) # <<<<<<<<<<<<<< * * # As of Cython 0.23.1, @cython.freelist cannot be used for */ __pyx_t_8 = PyObject_SetAttr(((PyObject *)__pyx_v_self), __pyx_v_k, __pyx_v_v); if (unlikely(__pyx_t_8 == -1)) __PYX_ERR(2, 624, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":622 * return state * * def __setstate__(self, state): # <<<<<<<<<<<<<< * for (k,v) in state.items(): * setattr(self, k, v) */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("llfuse.StatvfsData.__setstate__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_k); __Pyx_XDECREF(__pyx_v_v); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":642 * * @property * def errno(self): # <<<<<<<<<<<<<< * '''Error code to return to client process''' * return self.errno_ */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_9FUSEError_5errno_1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_9FUSEError_5errno_1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_9FUSEError_5errno___get__(((struct __pyx_obj_6llfuse_FUSEError *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_9FUSEError_5errno___get__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); /* "src/misc.pxi":644 * def errno(self): * '''Error code to return to client process''' * return self.errno_ # <<<<<<<<<<<<<< * * def __cinit__(self, errno): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->errno_); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 644, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":642 * * @property * def errno(self): # <<<<<<<<<<<<<< * '''Error code to return to client process''' * return self.errno_ */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.FUSEError.errno.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":646 * return self.errno_ * * def __cinit__(self, errno): # <<<<<<<<<<<<<< * self.errno_ = errno * */ /* Python wrapper */ static int __pyx_pw_6llfuse_9FUSEError_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static int __pyx_pw_6llfuse_9FUSEError_1__cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_errno = 0; int __pyx_r; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__cinit__ (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_errno,0}; PyObject* values[1] = {0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_errno)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__cinit__") < 0)) __PYX_ERR(2, 646, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 1) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); } __pyx_v_errno = values[0]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(2, 646, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.FUSEError.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return -1; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_9FUSEError___cinit__(((struct __pyx_obj_6llfuse_FUSEError *)__pyx_v_self), __pyx_v_errno); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static int __pyx_pf_6llfuse_9FUSEError___cinit__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self, PyObject *__pyx_v_errno) { int __pyx_r; __Pyx_RefNannyDeclarations int __pyx_t_1; __Pyx_RefNannySetupContext("__cinit__", 0); /* "src/misc.pxi":647 * * def __cinit__(self, errno): * self.errno_ = errno # <<<<<<<<<<<<<< * * def __str__(self): */ __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_errno); if (unlikely((__pyx_t_1 == (int)-1) && PyErr_Occurred())) __PYX_ERR(2, 647, __pyx_L1_error) __pyx_v_self->errno_ = __pyx_t_1; /* "src/misc.pxi":646 * return self.errno_ * * def __cinit__(self, errno): # <<<<<<<<<<<<<< * self.errno_ = errno * */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.FUSEError.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":649 * self.errno_ = errno * * def __str__(self): # <<<<<<<<<<<<<< * return strerror(self.errno_) * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_9FUSEError_3__str__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_9FUSEError_3__str__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__str__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_9FUSEError_2__str__(((struct __pyx_obj_6llfuse_FUSEError *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_9FUSEError_2__str__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__str__", 0); /* "src/misc.pxi":650 * * def __str__(self): * return strerror(self.errno_) # <<<<<<<<<<<<<< * * @cython.freelist(300) */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_f_6llfuse_strerror(__pyx_v_self->errno_); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 650, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/misc.pxi":649 * self.errno_ = errno * * def __str__(self): # <<<<<<<<<<<<<< * return strerror(self.errno_) * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.FUSEError.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":639 * # during C compilation (maybe something else declares errno as * # a macro?) * cdef readonly int errno_ # <<<<<<<<<<<<<< * * @property */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_9FUSEError_6errno__1__get__(PyObject *__pyx_v_self); /*proto*/ static PyObject *__pyx_pw_6llfuse_9FUSEError_6errno__1__get__(PyObject *__pyx_v_self) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__get__ (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_9FUSEError_6errno____get__(((struct __pyx_obj_6llfuse_FUSEError *)__pyx_v_self)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_9FUSEError_6errno____get__(struct __pyx_obj_6llfuse_FUSEError *__pyx_v_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("__get__", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->errno_); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 639, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.FUSEError.errno_.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":659 * cdef int kind * * cdef PyBytes_from_bufvec(fuse_bufvec *src): # <<<<<<<<<<<<<< * cdef fuse_bufvec dst * cdef size_t len_ */ static PyObject *__pyx_f_6llfuse_PyBytes_from_bufvec(struct fuse_bufvec *__pyx_v_src) { struct fuse_bufvec __pyx_v_dst; size_t __pyx_v_len_; Py_ssize_t __pyx_v_res; PyObject *__pyx_v_buf = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; __Pyx_RefNannySetupContext("PyBytes_from_bufvec", 0); /* "src/misc.pxi":664 * cdef ssize_t res * * len_ = fuse_buf_size(src) - src.off # <<<<<<<<<<<<<< * if len_ > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') */ __pyx_v_len_ = (fuse_buf_size(__pyx_v_src) - __pyx_v_src->off); /* "src/misc.pxi":665 * * len_ = fuse_buf_size(src) - src.off * if len_ > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * buf = PyBytes_FromStringAndSize(NULL, len_) */ __pyx_t_1 = ((__pyx_v_len_ > PY_SSIZE_T_MAX) != 0); if (__pyx_t_1) { /* "src/misc.pxi":666 * len_ = fuse_buf_size(src) - src.off * if len_ > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * buf = PyBytes_FromStringAndSize(NULL, len_) * dst.count = 1 */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_OverflowError, __pyx_tuple__59, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 666, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(2, 666, __pyx_L1_error) /* "src/misc.pxi":665 * * len_ = fuse_buf_size(src) - src.off * if len_ > PY_SSIZE_T_MAX: # <<<<<<<<<<<<<< * raise OverflowError('Value too long to convert to Python') * buf = PyBytes_FromStringAndSize(NULL, len_) */ } /* "src/misc.pxi":667 * if len_ > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') * buf = PyBytes_FromStringAndSize(NULL, len_) # <<<<<<<<<<<<<< * dst.count = 1 * dst.idx = 0 */ __pyx_t_2 = PyBytes_FromStringAndSize(NULL, ((Py_ssize_t)__pyx_v_len_)); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 667, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_v_buf = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; /* "src/misc.pxi":668 * raise OverflowError('Value too long to convert to Python') * buf = PyBytes_FromStringAndSize(NULL, len_) * dst.count = 1 # <<<<<<<<<<<<<< * dst.idx = 0 * dst.off = 0 */ __pyx_v_dst.count = 1; /* "src/misc.pxi":669 * buf = PyBytes_FromStringAndSize(NULL, len_) * dst.count = 1 * dst.idx = 0 # <<<<<<<<<<<<<< * dst.off = 0 * dst.buf[0].mem = PyBytes_AS_STRING(buf) */ __pyx_v_dst.idx = 0; /* "src/misc.pxi":670 * dst.count = 1 * dst.idx = 0 * dst.off = 0 # <<<<<<<<<<<<<< * dst.buf[0].mem = PyBytes_AS_STRING(buf) * dst.buf[0].size = len_ */ __pyx_v_dst.off = 0; /* "src/misc.pxi":671 * dst.idx = 0 * dst.off = 0 * dst.buf[0].mem = PyBytes_AS_STRING(buf) # <<<<<<<<<<<<<< * dst.buf[0].size = len_ * dst.buf[0].flags = 0 */ (__pyx_v_dst.buf[0]).mem = PyBytes_AS_STRING(__pyx_v_buf); /* "src/misc.pxi":672 * dst.off = 0 * dst.buf[0].mem = PyBytes_AS_STRING(buf) * dst.buf[0].size = len_ # <<<<<<<<<<<<<< * dst.buf[0].flags = 0 * res = fuse_buf_copy(&dst, src, 0) */ (__pyx_v_dst.buf[0]).size = __pyx_v_len_; /* "src/misc.pxi":673 * dst.buf[0].mem = PyBytes_AS_STRING(buf) * dst.buf[0].size = len_ * dst.buf[0].flags = 0 # <<<<<<<<<<<<<< * res = fuse_buf_copy(&dst, src, 0) * if res < 0: */ (__pyx_v_dst.buf[0]).flags = 0; /* "src/misc.pxi":674 * dst.buf[0].size = len_ * dst.buf[0].flags = 0 * res = fuse_buf_copy(&dst, src, 0) # <<<<<<<<<<<<<< * if res < 0: * raise OSError(errno.errno, 'fuse_buf_copy failed with ' */ __pyx_v_res = fuse_buf_copy((&__pyx_v_dst), __pyx_v_src, 0); /* "src/misc.pxi":675 * dst.buf[0].flags = 0 * res = fuse_buf_copy(&dst, src, 0) * if res < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'fuse_buf_copy failed with ' * + strerror(errno.errno)) */ __pyx_t_1 = ((__pyx_v_res < 0) != 0); if (__pyx_t_1) { /* "src/misc.pxi":676 * res = fuse_buf_copy(&dst, src, 0) * if res < 0: * raise OSError(errno.errno, 'fuse_buf_copy failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * elif res < len_: */ __pyx_t_2 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 676, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); /* "src/misc.pxi":677 * if res < 0: * raise OSError(errno.errno, 'fuse_buf_copy failed with ' * + strerror(errno.errno)) # <<<<<<<<<<<<<< * elif res < len_: * # This is expected to be rare */ __pyx_t_3 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 677, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = PyNumber_Add(__pyx_kp_u_fuse_buf_copy_failed_with, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 677, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/misc.pxi":676 * res = fuse_buf_copy(&dst, src, 0) * if res < 0: * raise OSError(errno.errno, 'fuse_buf_copy failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * elif res < len_: */ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 676, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 676, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 676, __pyx_L1_error) /* "src/misc.pxi":675 * dst.buf[0].flags = 0 * res = fuse_buf_copy(&dst, src, 0) * if res < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'fuse_buf_copy failed with ' * + strerror(errno.errno)) */ } /* "src/misc.pxi":678 * raise OSError(errno.errno, 'fuse_buf_copy failed with ' * + strerror(errno.errno)) * elif res < len_: # <<<<<<<<<<<<<< * # This is expected to be rare * return buf[:res] */ __pyx_t_1 = ((((size_t)__pyx_v_res) < __pyx_v_len_) != 0); if (__pyx_t_1) { /* "src/misc.pxi":680 * elif res < len_: * # This is expected to be rare * return buf[:res] # <<<<<<<<<<<<<< * else: * return buf */ __Pyx_XDECREF(__pyx_r); if (unlikely(__pyx_v_buf == Py_None)) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable"); __PYX_ERR(2, 680, __pyx_L1_error) } __pyx_t_4 = PySequence_GetSlice(__pyx_v_buf, 0, __pyx_v_res); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 680, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; /* "src/misc.pxi":678 * raise OSError(errno.errno, 'fuse_buf_copy failed with ' * + strerror(errno.errno)) * elif res < len_: # <<<<<<<<<<<<<< * # This is expected to be rare * return buf[:res] */ } /* "src/misc.pxi":682 * return buf[:res] * else: * return buf # <<<<<<<<<<<<<< * * cdef class VoidPtrCapsule: */ /*else*/ { __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_buf); __pyx_r = __pyx_v_buf; goto __pyx_L0; } /* "src/misc.pxi":659 * cdef int kind * * cdef PyBytes_from_bufvec(fuse_bufvec *src): # <<<<<<<<<<<<<< * cdef fuse_bufvec dst * cdef size_t len_ */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("llfuse.PyBytes_from_bufvec", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_buf); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":687 * cdef void* ptr * * cdef free_p(VoidPtrCapsule cap): # <<<<<<<<<<<<<< * stdlib.free(cap.ptr) * */ static PyObject *__pyx_f_6llfuse_free_p(struct __pyx_obj_6llfuse_VoidPtrCapsule *__pyx_v_cap) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("free_p", 0); /* "src/misc.pxi":688 * * cdef free_p(VoidPtrCapsule cap): * stdlib.free(cap.ptr) # <<<<<<<<<<<<<< * * cdef inline encap_ptr(void *ptr): */ free(__pyx_v_cap->ptr); /* "src/misc.pxi":687 * cdef void* ptr * * cdef free_p(VoidPtrCapsule cap): # <<<<<<<<<<<<<< * stdlib.free(cap.ptr) * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":690 * stdlib.free(cap.ptr) * * cdef inline encap_ptr(void *ptr): # <<<<<<<<<<<<<< * cdef VoidPtrCapsule cap * cap = VoidPtrCapsule.__new__(VoidPtrCapsule) */ static CYTHON_INLINE PyObject *__pyx_f_6llfuse_encap_ptr(void *__pyx_v_ptr) { struct __pyx_obj_6llfuse_VoidPtrCapsule *__pyx_v_cap = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("encap_ptr", 0); /* "src/misc.pxi":692 * cdef inline encap_ptr(void *ptr): * cdef VoidPtrCapsule cap * cap = VoidPtrCapsule.__new__(VoidPtrCapsule) # <<<<<<<<<<<<<< * cap.ptr = ptr * return cap */ __pyx_t_1 = __pyx_tp_new_6llfuse_VoidPtrCapsule(((PyTypeObject *)__pyx_ptype_6llfuse_VoidPtrCapsule), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 692, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_6llfuse_VoidPtrCapsule)))) __PYX_ERR(2, 692, __pyx_L1_error) __pyx_v_cap = ((struct __pyx_obj_6llfuse_VoidPtrCapsule *)__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":693 * cdef VoidPtrCapsule cap * cap = VoidPtrCapsule.__new__(VoidPtrCapsule) * cap.ptr = ptr # <<<<<<<<<<<<<< * return cap * */ __pyx_v_cap->ptr = __pyx_v_ptr; /* "src/misc.pxi":694 * cap = VoidPtrCapsule.__new__(VoidPtrCapsule) * cap.ptr = ptr * return cap # <<<<<<<<<<<<<< * * cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(((PyObject *)__pyx_v_cap)); __pyx_r = ((PyObject *)__pyx_v_cap); goto __pyx_L0; /* "src/misc.pxi":690 * stdlib.free(cap.ptr) * * cdef inline encap_ptr(void *ptr): # <<<<<<<<<<<<<< * cdef VoidPtrCapsule cap * cap = VoidPtrCapsule.__new__(VoidPtrCapsule) */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.encap_ptr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_cap); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":696 * return cap * * cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: # <<<<<<<<<<<<<< * global exit_reason * if session != NULL: */ static void __pyx_f_6llfuse_signal_handler(int __pyx_v_sig, CYTHON_UNUSED siginfo_t *__pyx_v_si, CYTHON_UNUSED void *__pyx_v_ctx) { int __pyx_t_1; /* "src/misc.pxi":698 * cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: * global exit_reason * if session != NULL: # <<<<<<<<<<<<<< * fuse_session_exit(session) * exit_reason = sig */ __pyx_t_1 = ((__pyx_v_6llfuse_session != NULL) != 0); if (__pyx_t_1) { /* "src/misc.pxi":699 * global exit_reason * if session != NULL: * fuse_session_exit(session) # <<<<<<<<<<<<<< * exit_reason = sig * */ fuse_session_exit(__pyx_v_6llfuse_session); /* "src/misc.pxi":698 * cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: * global exit_reason * if session != NULL: # <<<<<<<<<<<<<< * fuse_session_exit(session) * exit_reason = sig */ } /* "src/misc.pxi":700 * if session != NULL: * fuse_session_exit(session) * exit_reason = sig # <<<<<<<<<<<<<< * * cdef void do_nothing(int sig, siginfo_t *si, void* ctx) nogil: */ __pyx_v_6llfuse_exit_reason = __pyx_v_sig; /* "src/misc.pxi":696 * return cap * * cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: # <<<<<<<<<<<<<< * global exit_reason * if session != NULL: */ /* function exit code */ } /* "src/misc.pxi":702 * exit_reason = sig * * cdef void do_nothing(int sig, siginfo_t *si, void* ctx) nogil: # <<<<<<<<<<<<<< * pass * */ static void __pyx_f_6llfuse_do_nothing(CYTHON_UNUSED int __pyx_v_sig, CYTHON_UNUSED siginfo_t *__pyx_v_si, CYTHON_UNUSED void *__pyx_v_ctx) { /* function exit code */ } /* "src/misc.pxi":705 * pass * * cdef int sigaction_p(int sig, sigaction_t *sa, # <<<<<<<<<<<<<< * sigaction_t *old_sa) except -1: * cdef int res */ static int __pyx_f_6llfuse_sigaction_p(int __pyx_v_sig, struct sigaction *__pyx_v_sa, struct sigaction *__pyx_v_old_sa) { int __pyx_v_res; int __pyx_r; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; __Pyx_RefNannySetupContext("sigaction_p", 0); /* "src/misc.pxi":708 * sigaction_t *old_sa) except -1: * cdef int res * res = sigaction(sig, sa, old_sa) # <<<<<<<<<<<<<< * if res != 0: * raise OSError(errno.errno, 'sigaction failed with ' */ __pyx_v_res = sigaction(__pyx_v_sig, __pyx_v_sa, __pyx_v_old_sa); /* "src/misc.pxi":709 * cdef int res * res = sigaction(sig, sa, old_sa) * if res != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'sigaction failed with ' * + strerror(errno.errno)) */ __pyx_t_1 = ((__pyx_v_res != 0) != 0); if (__pyx_t_1) { /* "src/misc.pxi":710 * res = sigaction(sig, sa, old_sa) * if res != 0: * raise OSError(errno.errno, 'sigaction failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * return 0 */ __pyx_t_2 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_2)) __PYX_ERR(2, 710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); /* "src/misc.pxi":711 * if res != 0: * raise OSError(errno.errno, 'sigaction failed with ' * + strerror(errno.errno)) # <<<<<<<<<<<<<< * return 0 * */ __pyx_t_3 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 711, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = PyNumber_Add(__pyx_kp_u_sigaction_failed_with, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 711, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/misc.pxi":710 * res = sigaction(sig, sa, old_sa) * if res != 0: * raise OSError(errno.errno, 'sigaction failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * return 0 */ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(2, 710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(2, 710, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(2, 710, __pyx_L1_error) /* "src/misc.pxi":709 * cdef int res * res = sigaction(sig, sa, old_sa) * if res != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'sigaction failed with ' * + strerror(errno.errno)) */ } /* "src/misc.pxi":712 * raise OSError(errno.errno, 'sigaction failed with ' * + strerror(errno.errno)) * return 0 # <<<<<<<<<<<<<< * * cdef sigaction_t sa_backup[5] */ __pyx_r = 0; goto __pyx_L0; /* "src/misc.pxi":705 * pass * * cdef int sigaction_p(int sig, sigaction_t *sa, # <<<<<<<<<<<<<< * sigaction_t *old_sa) except -1: * cdef int res */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("llfuse.sigaction_p", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = -1; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":715 * * cdef sigaction_t sa_backup[5] * cdef set_signal_handlers(): # <<<<<<<<<<<<<< * cdef sigaction_t sa * */ static PyObject *__pyx_f_6llfuse_set_signal_handlers(void) { struct sigaction __pyx_v_sa; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; __Pyx_RefNannySetupContext("set_signal_handlers", 0); /* "src/misc.pxi":718 * cdef sigaction_t sa * * sigemptyset(&sa.sa_mask) # <<<<<<<<<<<<<< * sa.sa_sigaction = &signal_handler * sa.sa_flags = SA_SIGINFO */ sigemptyset((&__pyx_v_sa.sa_mask)); /* "src/misc.pxi":719 * * sigemptyset(&sa.sa_mask) * sa.sa_sigaction = &signal_handler # <<<<<<<<<<<<<< * sa.sa_flags = SA_SIGINFO * sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) */ __pyx_v_sa.sa_sigaction = (&__pyx_f_6llfuse_signal_handler); /* "src/misc.pxi":720 * sigemptyset(&sa.sa_mask) * sa.sa_sigaction = &signal_handler * sa.sa_flags = SA_SIGINFO # <<<<<<<<<<<<<< * sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) * sigaction_p(signal.SIGINT, &sa, &sa_backup[1]) */ __pyx_v_sa.sa_flags = SA_SIGINFO; /* "src/misc.pxi":721 * sa.sa_sigaction = &signal_handler * sa.sa_flags = SA_SIGINFO * sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGINT, &sa, &sa_backup[1]) * sigaction_p(signal.SIGHUP, &sa, &sa_backup[2]) */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGTERM, (&__pyx_v_sa), (&(__pyx_v_6llfuse_sa_backup[0]))); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 721, __pyx_L1_error) /* "src/misc.pxi":722 * sa.sa_flags = SA_SIGINFO * sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) * sigaction_p(signal.SIGINT, &sa, &sa_backup[1]) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGHUP, &sa, &sa_backup[2]) * */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGINT, (&__pyx_v_sa), (&(__pyx_v_6llfuse_sa_backup[1]))); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 722, __pyx_L1_error) /* "src/misc.pxi":723 * sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) * sigaction_p(signal.SIGINT, &sa, &sa_backup[1]) * sigaction_p(signal.SIGHUP, &sa, &sa_backup[2]) # <<<<<<<<<<<<<< * * # This is used to interrupt system calls without */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGHUP, (&__pyx_v_sa), (&(__pyx_v_6llfuse_sa_backup[2]))); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 723, __pyx_L1_error) /* "src/misc.pxi":727 * # This is used to interrupt system calls without * # doing anything else. * sa.sa_sigaction = &do_nothing # <<<<<<<<<<<<<< * sa.sa_flags = SA_SIGINFO * sigaction_p(signal.SIGUSR1, &sa, &sa_backup[3]) */ __pyx_v_sa.sa_sigaction = (&__pyx_f_6llfuse_do_nothing); /* "src/misc.pxi":728 * # doing anything else. * sa.sa_sigaction = &do_nothing * sa.sa_flags = SA_SIGINFO # <<<<<<<<<<<<<< * sigaction_p(signal.SIGUSR1, &sa, &sa_backup[3]) * */ __pyx_v_sa.sa_flags = SA_SIGINFO; /* "src/misc.pxi":729 * sa.sa_sigaction = &do_nothing * sa.sa_flags = SA_SIGINFO * sigaction_p(signal.SIGUSR1, &sa, &sa_backup[3]) # <<<<<<<<<<<<<< * * sa.sa_handler = signal.SIG_IGN */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGUSR1, (&__pyx_v_sa), (&(__pyx_v_6llfuse_sa_backup[3]))); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 729, __pyx_L1_error) /* "src/misc.pxi":731 * sigaction_p(signal.SIGUSR1, &sa, &sa_backup[3]) * * sa.sa_handler = signal.SIG_IGN # <<<<<<<<<<<<<< * sa.sa_flags = 0 * sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) */ __pyx_v_sa.sa_handler = SIG_IGN; /* "src/misc.pxi":732 * * sa.sa_handler = signal.SIG_IGN * sa.sa_flags = 0 # <<<<<<<<<<<<<< * sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) * */ __pyx_v_sa.sa_flags = 0; /* "src/misc.pxi":733 * sa.sa_handler = signal.SIG_IGN * sa.sa_flags = 0 * sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) # <<<<<<<<<<<<<< * * cdef restore_signal_handlers(): */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGPIPE, (&__pyx_v_sa), (&(__pyx_v_6llfuse_sa_backup[4]))); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 733, __pyx_L1_error) /* "src/misc.pxi":715 * * cdef sigaction_t sa_backup[5] * cdef set_signal_handlers(): # <<<<<<<<<<<<<< * cdef sigaction_t sa * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.set_signal_handlers", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":735 * sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) * * cdef restore_signal_handlers(): # <<<<<<<<<<<<<< * sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) */ static PyObject *__pyx_f_6llfuse_restore_signal_handlers(void) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; __Pyx_RefNannySetupContext("restore_signal_handlers", 0); /* "src/misc.pxi":736 * * cdef restore_signal_handlers(): * sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) * sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGTERM, (&(__pyx_v_6llfuse_sa_backup[0])), NULL); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 736, __pyx_L1_error) /* "src/misc.pxi":737 * cdef restore_signal_handlers(): * sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) * sigaction_p(signal.SIGUSR1, &sa_backup[3], NULL) */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGINT, (&(__pyx_v_6llfuse_sa_backup[1])), NULL); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 737, __pyx_L1_error) /* "src/misc.pxi":738 * sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) * sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGUSR1, &sa_backup[3], NULL) * sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGHUP, (&(__pyx_v_6llfuse_sa_backup[2])), NULL); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 738, __pyx_L1_error) /* "src/misc.pxi":739 * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) * sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) * sigaction_p(signal.SIGUSR1, &sa_backup[3], NULL) # <<<<<<<<<<<<<< * sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) * */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGUSR1, (&(__pyx_v_6llfuse_sa_backup[3])), NULL); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 739, __pyx_L1_error) /* "src/misc.pxi":740 * sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) * sigaction_p(signal.SIGUSR1, &sa_backup[3], NULL) * sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) # <<<<<<<<<<<<<< * * cdef void* calloc_or_raise(size_t nmemb, size_t size) except NULL: */ __pyx_t_1 = __pyx_f_6llfuse_sigaction_p(SIGPIPE, (&(__pyx_v_6llfuse_sa_backup[4])), NULL); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(2, 740, __pyx_L1_error) /* "src/misc.pxi":735 * sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) * * cdef restore_signal_handlers(): # <<<<<<<<<<<<<< * sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) * sigaction_p(signal.SIGINT, &sa_backup[1], NULL) */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_AddTraceback("llfuse.restore_signal_handlers", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/misc.pxi":742 * sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) * * cdef void* calloc_or_raise(size_t nmemb, size_t size) except NULL: # <<<<<<<<<<<<<< * cdef void* mem * mem = stdlib.calloc(nmemb, size) */ static void *__pyx_f_6llfuse_calloc_or_raise(size_t __pyx_v_nmemb, size_t __pyx_v_size) { void *__pyx_v_mem; void *__pyx_r; __Pyx_RefNannyDeclarations int __pyx_t_1; __Pyx_RefNannySetupContext("calloc_or_raise", 0); /* "src/misc.pxi":744 * cdef void* calloc_or_raise(size_t nmemb, size_t size) except NULL: * cdef void* mem * mem = stdlib.calloc(nmemb, size) # <<<<<<<<<<<<<< * if mem is NULL: * raise MemoryError() */ __pyx_v_mem = calloc(__pyx_v_nmemb, __pyx_v_size); /* "src/misc.pxi":745 * cdef void* mem * mem = stdlib.calloc(nmemb, size) * if mem is NULL: # <<<<<<<<<<<<<< * raise MemoryError() * return mem */ __pyx_t_1 = ((__pyx_v_mem == NULL) != 0); if (__pyx_t_1) { /* "src/misc.pxi":746 * mem = stdlib.calloc(nmemb, size) * if mem is NULL: * raise MemoryError() # <<<<<<<<<<<<<< * return mem */ PyErr_NoMemory(); __PYX_ERR(2, 746, __pyx_L1_error) /* "src/misc.pxi":745 * cdef void* mem * mem = stdlib.calloc(nmemb, size) * if mem is NULL: # <<<<<<<<<<<<<< * raise MemoryError() * return mem */ } /* "src/misc.pxi":747 * if mem is NULL: * raise MemoryError() * return mem # <<<<<<<<<<<<<< */ __pyx_r = __pyx_v_mem; goto __pyx_L0; /* "src/misc.pxi":742 * sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) * * cdef void* calloc_or_raise(size_t nmemb, size_t size) except NULL: # <<<<<<<<<<<<<< * cdef void* mem * mem = stdlib.calloc(nmemb, size) */ /* function exit code */ __pyx_L1_error:; __Pyx_AddTraceback("llfuse.calloc_or_raise", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":14 * ''' * * def listdir(path): # <<<<<<<<<<<<<< * '''Like `os.listdir`, but releases the GIL. * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_3listdir(PyObject *__pyx_self, PyObject *__pyx_v_path); /*proto*/ static char __pyx_doc_6llfuse_2listdir[] = "listdir(path)\nLike `os.listdir`, but releases the GIL.\n\n This function returns an iterator over the directory entries in\n *path*. The returned values are of type :ref:`str\n ` in both Python 2.x and 3.x.\n\n In Python 2.x :class:`str` is equivalent to `bytes` so all names\n can be represented. In Python 3.x, surrogate escape coding (cf.\n `PEP 383 `_) is used for\n directory names that do not have a string representation.\n "; static PyMethodDef __pyx_mdef_6llfuse_3listdir = {"listdir", (PyCFunction)__pyx_pw_6llfuse_3listdir, METH_O, __pyx_doc_6llfuse_2listdir}; static PyObject *__pyx_pw_6llfuse_3listdir(PyObject *__pyx_self, PyObject *__pyx_v_path) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("listdir (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_2listdir(__pyx_self, ((PyObject *)__pyx_v_path)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_2listdir(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path) { DIR *__pyx_v_dirp; struct dirent *__pyx_v_res; char *__pyx_v_buf; PyObject *__pyx_v_path_b = NULL; PyObject *__pyx_v_names = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; int __pyx_t_3; char *__pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; int __pyx_t_7; __Pyx_RefNannySetupContext("listdir", 0); /* "src/fuse_api.pxi":27 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 27, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyObject_IsInstance(__pyx_v_path, __pyx_t_1); if (unlikely(__pyx_t_2 == -1)) __PYX_ERR(3, 27, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":28 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * cdef dirent.DIR* dirp */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__60, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 28, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 28, __pyx_L1_error) /* "src/fuse_api.pxi":27 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ } /* "src/fuse_api.pxi":34 * cdef char* buf * * path_b = str2bytes(path) # <<<<<<<<<<<<<< * buf = path_b * */ __pyx_t_1 = __pyx_f_6llfuse_str2bytes(__pyx_v_path); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 34, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_path_b = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":35 * * path_b = str2bytes(path) * buf = path_b # <<<<<<<<<<<<<< * * with nogil: */ __pyx_t_4 = __Pyx_PyObject_AsString(__pyx_v_path_b); if (unlikely((!__pyx_t_4) && PyErr_Occurred())) __PYX_ERR(3, 35, __pyx_L1_error) __pyx_v_buf = ((char *)__pyx_t_4); /* "src/fuse_api.pxi":37 * buf = path_b * * with nogil: # <<<<<<<<<<<<<< * dirp = dirent.opendir(buf) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":38 * * with nogil: * dirp = dirent.opendir(buf) # <<<<<<<<<<<<<< * * if dirp == NULL: */ __pyx_v_dirp = opendir(__pyx_v_buf); } /* "src/fuse_api.pxi":37 * buf = path_b * * with nogil: # <<<<<<<<<<<<<< * dirp = dirent.opendir(buf) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L6; } __pyx_L6:; } } /* "src/fuse_api.pxi":40 * dirp = dirent.opendir(buf) * * if dirp == NULL: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ __pyx_t_3 = ((__pyx_v_dirp == NULL) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":41 * * if dirp == NULL: * raise OSError(errno.errno, strerror(errno.errno), path) # <<<<<<<<<<<<<< * * names = list() */ __pyx_t_1 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 41, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_5 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 41, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = PyTuple_New(3); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 41, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_5); __Pyx_INCREF(__pyx_v_path); __Pyx_GIVEREF(__pyx_v_path); PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_v_path); __pyx_t_1 = 0; __pyx_t_5 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 41, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_Raise(__pyx_t_5, 0, 0, 0); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(3, 41, __pyx_L1_error) /* "src/fuse_api.pxi":40 * dirp = dirent.opendir(buf) * * if dirp == NULL: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ } /* "src/fuse_api.pxi":43 * raise OSError(errno.errno, strerror(errno.errno), path) * * names = list() # <<<<<<<<<<<<<< * while True: * errno.errno = 0 */ __pyx_t_5 = PyList_New(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 43, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_v_names = ((PyObject*)__pyx_t_5); __pyx_t_5 = 0; /* "src/fuse_api.pxi":44 * * names = list() * while True: # <<<<<<<<<<<<<< * errno.errno = 0 * with nogil: */ while (1) { /* "src/fuse_api.pxi":45 * names = list() * while True: * errno.errno = 0 # <<<<<<<<<<<<<< * with nogil: * res = dirent.readdir(dirp) */ errno = 0; /* "src/fuse_api.pxi":46 * while True: * errno.errno = 0 * with nogil: # <<<<<<<<<<<<<< * res = dirent.readdir(dirp) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":47 * errno.errno = 0 * with nogil: * res = dirent.readdir(dirp) # <<<<<<<<<<<<<< * * if res is NULL: */ __pyx_v_res = readdir(__pyx_v_dirp); } /* "src/fuse_api.pxi":46 * while True: * errno.errno = 0 * with nogil: # <<<<<<<<<<<<<< * res = dirent.readdir(dirp) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L14; } __pyx_L14:; } } /* "src/fuse_api.pxi":49 * res = dirent.readdir(dirp) * * if res is NULL: # <<<<<<<<<<<<<< * if errno.errno != 0: * raise OSError(errno.errno, strerror(errno.errno), path) */ __pyx_t_3 = ((__pyx_v_res == NULL) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":50 * * if res is NULL: * if errno.errno != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * else: */ __pyx_t_3 = ((errno != 0) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":51 * if res is NULL: * if errno.errno != 0: * raise OSError(errno.errno, strerror(errno.errno), path) # <<<<<<<<<<<<<< * else: * break */ __pyx_t_5 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_6 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_5); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_6); __Pyx_INCREF(__pyx_v_path); __Pyx_GIVEREF(__pyx_v_path); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_path); __pyx_t_5 = 0; __pyx_t_6 = 0; __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_1, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 51, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_6, 0, 0, 0); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __PYX_ERR(3, 51, __pyx_L1_error) /* "src/fuse_api.pxi":50 * * if res is NULL: * if errno.errno != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * else: */ } /* "src/fuse_api.pxi":53 * raise OSError(errno.errno, strerror(errno.errno), path) * else: * break # <<<<<<<<<<<<<< * if string.strcmp(res.d_name, b'.') == 0 or \ * string.strcmp(res.d_name, b'..') == 0: */ /*else*/ { goto __pyx_L9_break; } /* "src/fuse_api.pxi":49 * res = dirent.readdir(dirp) * * if res is NULL: # <<<<<<<<<<<<<< * if errno.errno != 0: * raise OSError(errno.errno, strerror(errno.errno), path) */ } /* "src/fuse_api.pxi":54 * else: * break * if string.strcmp(res.d_name, b'.') == 0 or \ # <<<<<<<<<<<<<< * string.strcmp(res.d_name, b'..') == 0: * continue */ __pyx_t_2 = ((strcmp(__pyx_v_res->d_name, ((char const *)".")) == 0) != 0); if (!__pyx_t_2) { } else { __pyx_t_3 = __pyx_t_2; goto __pyx_L18_bool_binop_done; } /* "src/fuse_api.pxi":55 * break * if string.strcmp(res.d_name, b'.') == 0 or \ * string.strcmp(res.d_name, b'..') == 0: # <<<<<<<<<<<<<< * continue * */ __pyx_t_2 = ((strcmp(__pyx_v_res->d_name, ((char const *)"..")) == 0) != 0); __pyx_t_3 = __pyx_t_2; __pyx_L18_bool_binop_done:; /* "src/fuse_api.pxi":54 * else: * break * if string.strcmp(res.d_name, b'.') == 0 or \ # <<<<<<<<<<<<<< * string.strcmp(res.d_name, b'..') == 0: * continue */ if (__pyx_t_3) { /* "src/fuse_api.pxi":56 * if string.strcmp(res.d_name, b'.') == 0 or \ * string.strcmp(res.d_name, b'..') == 0: * continue # <<<<<<<<<<<<<< * * names.append(bytes2str(PyBytes_FromString(res.d_name))) */ goto __pyx_L8_continue; /* "src/fuse_api.pxi":54 * else: * break * if string.strcmp(res.d_name, b'.') == 0 or \ # <<<<<<<<<<<<<< * string.strcmp(res.d_name, b'..') == 0: * continue */ } /* "src/fuse_api.pxi":58 * continue * * names.append(bytes2str(PyBytes_FromString(res.d_name))) # <<<<<<<<<<<<<< * * with nogil: */ __pyx_t_6 = PyBytes_FromString(__pyx_v_res->d_name); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 58, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_1 = __pyx_f_6llfuse_bytes2str(__pyx_t_6); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 58, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __pyx_t_7 = __Pyx_PyList_Append(__pyx_v_names, __pyx_t_1); if (unlikely(__pyx_t_7 == -1)) __PYX_ERR(3, 58, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_L8_continue:; } __pyx_L9_break:; /* "src/fuse_api.pxi":60 * names.append(bytes2str(PyBytes_FromString(res.d_name))) * * with nogil: # <<<<<<<<<<<<<< * dirent.closedir(dirp) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":61 * * with nogil: * dirent.closedir(dirp) # <<<<<<<<<<<<<< * * return names */ closedir(__pyx_v_dirp); } /* "src/fuse_api.pxi":60 * names.append(bytes2str(PyBytes_FromString(res.d_name))) * * with nogil: # <<<<<<<<<<<<<< * dirent.closedir(dirp) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L22; } __pyx_L22:; } } /* "src/fuse_api.pxi":63 * dirent.closedir(dirp) * * return names # <<<<<<<<<<<<<< * * */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_names); __pyx_r = __pyx_v_names; goto __pyx_L0; /* "src/fuse_api.pxi":14 * ''' * * def listdir(path): # <<<<<<<<<<<<<< * '''Like `os.listdir`, but releases the GIL. * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("llfuse.listdir", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_path_b); __Pyx_XDECREF(__pyx_v_names); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":66 * * * def setxattr(path, name, bytes value, namespace='user'): # <<<<<<<<<<<<<< * '''Set extended attribute * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_5setxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_4setxattr[] = "setxattr(path, name, bytes value, namespace=u'user')\nSet extended attribute\n\n *path* and *name* have to be of type `str`. In Python 3.x, they may\n contain surrogates. *value* has to be of type `bytes`.\n\n Under FreeBSD, the *namespace* parameter may be set to *system* or *user* to\n select the namespace for the extended attribute. For other platforms, this\n parameter is ignored.\n\n In contrast the `os.setxattr` function from the standard library,\n the method provided by Python-LLFUSE is also available for non-Linux\n systems.\n "; static PyMethodDef __pyx_mdef_6llfuse_5setxattr = {"setxattr", (PyCFunction)__pyx_pw_6llfuse_5setxattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_4setxattr}; static PyObject *__pyx_pw_6llfuse_5setxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_path = 0; PyObject *__pyx_v_name = 0; PyObject *__pyx_v_value = 0; PyObject *__pyx_v_namespace = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("setxattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_path,&__pyx_n_s_name,&__pyx_n_s_value,&__pyx_n_s_namespace,0}; PyObject* values[4] = {0,0,0,0}; values[3] = ((PyObject *)__pyx_n_u_user); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_path)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 0, 3, 4, 1); __PYX_ERR(3, 66, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_value)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("setxattr", 0, 3, 4, 2); __PYX_ERR(3, 66, __pyx_L3_error) } case 3: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_namespace); if (value) { values[3] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "setxattr") < 0)) __PYX_ERR(3, 66, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[0] = PyTuple_GET_ITEM(__pyx_args, 0); break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_path = values[0]; __pyx_v_name = values[1]; __pyx_v_value = ((PyObject*)values[2]); __pyx_v_namespace = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("setxattr", 0, 3, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 66, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_value), (&PyBytes_Type), 1, "value", 1))) __PYX_ERR(3, 66, __pyx_L1_error) __pyx_r = __pyx_pf_6llfuse_4setxattr(__pyx_self, __pyx_v_path, __pyx_v_name, __pyx_v_value, __pyx_v_namespace); /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __pyx_r = NULL; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_4setxattr(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path, PyObject *__pyx_v_name, PyObject *__pyx_v_value, PyObject *__pyx_v_namespace) { int __pyx_v_ret; Py_ssize_t __pyx_v_len_; char *__pyx_v_cvalue; char *__pyx_v_cpath; char *__pyx_v_cname; int __pyx_v_cnamespace; PyObject *__pyx_v_path_b = NULL; PyObject *__pyx_v_name_b = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; int __pyx_t_3; PyObject *__pyx_t_4 = NULL; int __pyx_t_5; char *__pyx_t_6; PyObject *__pyx_t_7 = NULL; __Pyx_RefNannySetupContext("setxattr", 0); /* "src/fuse_api.pxi":81 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 81, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyObject_IsInstance(__pyx_v_path, __pyx_t_1); if (unlikely(__pyx_t_2 == -1)) __PYX_ERR(3, 81, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":82 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * if not isinstance(name, str_t): */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__61, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 82, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 82, __pyx_L1_error) /* "src/fuse_api.pxi":81 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ } /* "src/fuse_api.pxi":84 * raise TypeError('*path* argument must be of type str') * * if not isinstance(name, str_t): # <<<<<<<<<<<<<< * raise TypeError('*name* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 84, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyObject_IsInstance(__pyx_v_name, __pyx_t_1); if (unlikely(__pyx_t_3 == -1)) __PYX_ERR(3, 84, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_2 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_2) { /* "src/fuse_api.pxi":85 * * if not isinstance(name, str_t): * raise TypeError('*name* argument must be of type str') # <<<<<<<<<<<<<< * * if namespace not in ('system', 'user'): */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__62, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 85, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 85, __pyx_L1_error) /* "src/fuse_api.pxi":84 * raise TypeError('*path* argument must be of type str') * * if not isinstance(name, str_t): # <<<<<<<<<<<<<< * raise TypeError('*name* argument must be of type str') * */ } /* "src/fuse_api.pxi":87 * raise TypeError('*name* argument must be of type str') * * if namespace not in ('system', 'user'): # <<<<<<<<<<<<<< * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) */ __Pyx_INCREF(__pyx_v_namespace); __pyx_t_1 = __pyx_v_namespace; __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_n_u_system, Py_NE)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 87, __pyx_L1_error) if (__pyx_t_3) { } else { __pyx_t_2 = __pyx_t_3; goto __pyx_L6_bool_binop_done; } __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_n_u_user, Py_NE)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 87, __pyx_L1_error) __pyx_t_2 = __pyx_t_3; __pyx_L6_bool_binop_done:; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":89 * if namespace not in ('system', 'user'): * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) # <<<<<<<<<<<<<< * * cdef int ret */ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_namespace_parameter_must_be_sys, __pyx_v_namespace); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 89, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); /* "src/fuse_api.pxi":88 * * if namespace not in ('system', 'user'): * raise ValueError('*namespace* parameter must be "system" or "user", not %s' # <<<<<<<<<<<<<< * % namespace) * */ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 88, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 88, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 88, __pyx_L1_error) /* "src/fuse_api.pxi":87 * raise TypeError('*name* argument must be of type str') * * if namespace not in ('system', 'user'): # <<<<<<<<<<<<<< * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) */ } /* "src/fuse_api.pxi":98 * cdef int cnamespace * * if namespace == 'system': # <<<<<<<<<<<<<< * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: */ __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_namespace, __pyx_n_u_system, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 98, __pyx_L1_error) if (__pyx_t_3) { /* "src/fuse_api.pxi":99 * * if namespace == 'system': * cnamespace = EXTATTR_NAMESPACE_SYSTEM # <<<<<<<<<<<<<< * else: * cnamespace = EXTATTR_NAMESPACE_USER */ __pyx_v_cnamespace = EXTATTR_NAMESPACE_SYSTEM; /* "src/fuse_api.pxi":98 * cdef int cnamespace * * if namespace == 'system': # <<<<<<<<<<<<<< * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: */ goto __pyx_L8; } /* "src/fuse_api.pxi":101 * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: * cnamespace = EXTATTR_NAMESPACE_USER # <<<<<<<<<<<<<< * * path_b = str2bytes(path) */ /*else*/ { __pyx_v_cnamespace = EXTATTR_NAMESPACE_USER; } __pyx_L8:; /* "src/fuse_api.pxi":103 * cnamespace = EXTATTR_NAMESPACE_USER * * path_b = str2bytes(path) # <<<<<<<<<<<<<< * name_b = str2bytes(name) * PyBytes_AsStringAndSize(value, &cvalue, &len_) */ __pyx_t_1 = __pyx_f_6llfuse_str2bytes(__pyx_v_path); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 103, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_path_b = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":104 * * path_b = str2bytes(path) * name_b = str2bytes(name) # <<<<<<<<<<<<<< * PyBytes_AsStringAndSize(value, &cvalue, &len_) * cpath = path_b */ __pyx_t_1 = __pyx_f_6llfuse_str2bytes(__pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 104, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_name_b = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":105 * path_b = str2bytes(path) * name_b = str2bytes(name) * PyBytes_AsStringAndSize(value, &cvalue, &len_) # <<<<<<<<<<<<<< * cpath = path_b * cname = name_b */ __pyx_t_5 = PyBytes_AsStringAndSize(__pyx_v_value, (&__pyx_v_cvalue), (&__pyx_v_len_)); if (unlikely(__pyx_t_5 == -1)) __PYX_ERR(3, 105, __pyx_L1_error) /* "src/fuse_api.pxi":106 * name_b = str2bytes(name) * PyBytes_AsStringAndSize(value, &cvalue, &len_) * cpath = path_b # <<<<<<<<<<<<<< * cname = name_b * */ __pyx_t_6 = __Pyx_PyObject_AsString(__pyx_v_path_b); if (unlikely((!__pyx_t_6) && PyErr_Occurred())) __PYX_ERR(3, 106, __pyx_L1_error) __pyx_v_cpath = ((char *)__pyx_t_6); /* "src/fuse_api.pxi":107 * PyBytes_AsStringAndSize(value, &cvalue, &len_) * cpath = path_b * cname = name_b # <<<<<<<<<<<<<< * * with nogil: */ __pyx_t_6 = __Pyx_PyObject_AsString(__pyx_v_name_b); if (unlikely((!__pyx_t_6) && PyErr_Occurred())) __PYX_ERR(3, 107, __pyx_L1_error) __pyx_v_cname = ((char *)__pyx_t_6); /* "src/fuse_api.pxi":109 * cname = name_b * * with nogil: # <<<<<<<<<<<<<< * # len_ is guaranteed positive * ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":111 * with nogil: * # len_ is guaranteed positive * ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) # <<<<<<<<<<<<<< * * if ret != 0: */ __pyx_v_ret = setxattr_p(__pyx_v_cpath, __pyx_v_cname, __pyx_v_cvalue, ((size_t)__pyx_v_len_), __pyx_v_cnamespace); } /* "src/fuse_api.pxi":109 * cname = name_b * * with nogil: # <<<<<<<<<<<<<< * # len_ is guaranteed positive * ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L11; } __pyx_L11:; } } /* "src/fuse_api.pxi":113 * ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) * * if ret != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ __pyx_t_3 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":114 * * if ret != 0: * raise OSError(errno.errno, strerror(errno.errno), path) # <<<<<<<<<<<<<< * * */ __pyx_t_1 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 114, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_4 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 114, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = PyTuple_New(3); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 114, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_1); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_path); __Pyx_GIVEREF(__pyx_v_path); PyTuple_SET_ITEM(__pyx_t_7, 2, __pyx_v_path); __pyx_t_1 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 114, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(3, 114, __pyx_L1_error) /* "src/fuse_api.pxi":113 * ret = setxattr_p(cpath, cname, cvalue, len_, cnamespace) * * if ret != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ } /* "src/fuse_api.pxi":66 * * * def setxattr(path, name, bytes value, namespace='user'): # <<<<<<<<<<<<<< * '''Set extended attribute * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("llfuse.setxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_path_b); __Pyx_XDECREF(__pyx_v_name_b); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":117 * * * def getxattr(path, name, size_t size_guess=128, namespace='user'): # <<<<<<<<<<<<<< * '''Get extended attribute * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_7getxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_6getxattr[] = "getxattr(path, name, size_t size_guess=128, namespace=u'user')\nGet extended attribute\n\n *path* and *name* have to be of type `str`. In Python 3.x, they may\n contain surrogates. Returns a value of type `bytes`.\n\n If the caller knows the approximate size of the attribute value,\n it should be supplied in *size_guess*. If the guess turns out\n to be wrong, the system call has to be carried out three times\n (the first call will fail, the second determines the size and\n the third finally gets the value).\n\n Under FreeBSD, the *namespace* parameter may be set to *system* or *user* to\n select the namespace for the extended attribute. For other platforms, this\n parameter is ignored.\n\n In contrast the `os.setxattr` function from the standard library,\n the method provided by Python-LLFUSE is also available for non-Linux\n systems.\n "; static PyMethodDef __pyx_mdef_6llfuse_7getxattr = {"getxattr", (PyCFunction)__pyx_pw_6llfuse_7getxattr, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_6getxattr}; static PyObject *__pyx_pw_6llfuse_7getxattr(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_path = 0; PyObject *__pyx_v_name = 0; size_t __pyx_v_size_guess; PyObject *__pyx_v_namespace = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("getxattr (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_path,&__pyx_n_s_name,&__pyx_n_s_size_guess,&__pyx_n_s_namespace,0}; PyObject* values[4] = {0,0,0,0}; values[3] = ((PyObject *)__pyx_n_u_user); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_path)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("getxattr", 0, 2, 4, 1); __PYX_ERR(3, 117, __pyx_L3_error) } case 2: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_size_guess); if (value) { values[2] = value; kw_args--; } } case 3: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_namespace); if (value) { values[3] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "getxattr") < 0)) __PYX_ERR(3, 117, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3); case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[0] = PyTuple_GET_ITEM(__pyx_args, 0); break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_path = values[0]; __pyx_v_name = values[1]; if (values[2]) { __pyx_v_size_guess = __Pyx_PyInt_As_size_t(values[2]); if (unlikely((__pyx_v_size_guess == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(3, 117, __pyx_L3_error) } else { __pyx_v_size_guess = ((size_t)0x80); } __pyx_v_namespace = values[3]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("getxattr", 0, 2, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 117, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_6getxattr(__pyx_self, __pyx_v_path, __pyx_v_name, __pyx_v_size_guess, __pyx_v_namespace); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_6getxattr(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_path, PyObject *__pyx_v_name, size_t __pyx_v_size_guess, PyObject *__pyx_v_namespace) { Py_ssize_t __pyx_v_ret; char *__pyx_v_buf; char *__pyx_v_cpath; char *__pyx_v_cname; size_t __pyx_v_bufsize; int __pyx_v_cnamespace; PyObject *__pyx_v_path_b = NULL; PyObject *__pyx_v_name_b = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; int __pyx_t_3; PyObject *__pyx_t_4 = NULL; char *__pyx_t_5; PyObject *__pyx_t_6; PyObject *__pyx_t_7 = NULL; int __pyx_t_8; int __pyx_t_9; char const *__pyx_t_10; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; __Pyx_RefNannySetupContext("getxattr", 0); /* "src/fuse_api.pxi":138 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 138, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyObject_IsInstance(__pyx_v_path, __pyx_t_1); if (unlikely(__pyx_t_2 == -1)) __PYX_ERR(3, 138, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = ((!(__pyx_t_2 != 0)) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":139 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * if not isinstance(name, str_t): */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__63, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 139, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 139, __pyx_L1_error) /* "src/fuse_api.pxi":138 * ''' * * if not isinstance(path, str_t): # <<<<<<<<<<<<<< * raise TypeError('*path* argument must be of type str') * */ } /* "src/fuse_api.pxi":141 * raise TypeError('*path* argument must be of type str') * * if not isinstance(name, str_t): # <<<<<<<<<<<<<< * raise TypeError('*name* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 141, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyObject_IsInstance(__pyx_v_name, __pyx_t_1); if (unlikely(__pyx_t_3 == -1)) __PYX_ERR(3, 141, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_2 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_2) { /* "src/fuse_api.pxi":142 * * if not isinstance(name, str_t): * raise TypeError('*name* argument must be of type str') # <<<<<<<<<<<<<< * * if namespace not in ('system', 'user'): */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__64, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 142, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 142, __pyx_L1_error) /* "src/fuse_api.pxi":141 * raise TypeError('*path* argument must be of type str') * * if not isinstance(name, str_t): # <<<<<<<<<<<<<< * raise TypeError('*name* argument must be of type str') * */ } /* "src/fuse_api.pxi":144 * raise TypeError('*name* argument must be of type str') * * if namespace not in ('system', 'user'): # <<<<<<<<<<<<<< * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) */ __Pyx_INCREF(__pyx_v_namespace); __pyx_t_1 = __pyx_v_namespace; __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_n_u_system, Py_NE)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 144, __pyx_L1_error) if (__pyx_t_3) { } else { __pyx_t_2 = __pyx_t_3; goto __pyx_L6_bool_binop_done; } __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_n_u_user, Py_NE)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 144, __pyx_L1_error) __pyx_t_2 = __pyx_t_3; __pyx_L6_bool_binop_done:; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__pyx_t_2 != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":146 * if namespace not in ('system', 'user'): * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) # <<<<<<<<<<<<<< * * cdef ssize_t ret */ __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_namespace_parameter_must_be_sys, __pyx_v_namespace); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); /* "src/fuse_api.pxi":145 * * if namespace not in ('system', 'user'): * raise ValueError('*namespace* parameter must be "system" or "user", not %s' # <<<<<<<<<<<<<< * % namespace) * */ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 145, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 145, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 145, __pyx_L1_error) /* "src/fuse_api.pxi":144 * raise TypeError('*name* argument must be of type str') * * if namespace not in ('system', 'user'): # <<<<<<<<<<<<<< * raise ValueError('*namespace* parameter must be "system" or "user", not %s' * % namespace) */ } /* "src/fuse_api.pxi":155 * cdef int cnamespace * * if namespace == 'system': # <<<<<<<<<<<<<< * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: */ __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_namespace, __pyx_n_u_system, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 155, __pyx_L1_error) if (__pyx_t_3) { /* "src/fuse_api.pxi":156 * * if namespace == 'system': * cnamespace = EXTATTR_NAMESPACE_SYSTEM # <<<<<<<<<<<<<< * else: * cnamespace = EXTATTR_NAMESPACE_USER */ __pyx_v_cnamespace = EXTATTR_NAMESPACE_SYSTEM; /* "src/fuse_api.pxi":155 * cdef int cnamespace * * if namespace == 'system': # <<<<<<<<<<<<<< * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: */ goto __pyx_L8; } /* "src/fuse_api.pxi":158 * cnamespace = EXTATTR_NAMESPACE_SYSTEM * else: * cnamespace = EXTATTR_NAMESPACE_USER # <<<<<<<<<<<<<< * * path_b = str2bytes(path) */ /*else*/ { __pyx_v_cnamespace = EXTATTR_NAMESPACE_USER; } __pyx_L8:; /* "src/fuse_api.pxi":160 * cnamespace = EXTATTR_NAMESPACE_USER * * path_b = str2bytes(path) # <<<<<<<<<<<<<< * name_b = str2bytes(name) * cpath = path_b */ __pyx_t_1 = __pyx_f_6llfuse_str2bytes(__pyx_v_path); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 160, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_path_b = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":161 * * path_b = str2bytes(path) * name_b = str2bytes(name) # <<<<<<<<<<<<<< * cpath = path_b * cname = name_b */ __pyx_t_1 = __pyx_f_6llfuse_str2bytes(__pyx_v_name); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 161, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_v_name_b = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":162 * path_b = str2bytes(path) * name_b = str2bytes(name) * cpath = path_b # <<<<<<<<<<<<<< * cname = name_b * */ __pyx_t_5 = __Pyx_PyObject_AsString(__pyx_v_path_b); if (unlikely((!__pyx_t_5) && PyErr_Occurred())) __PYX_ERR(3, 162, __pyx_L1_error) __pyx_v_cpath = ((char *)__pyx_t_5); /* "src/fuse_api.pxi":163 * name_b = str2bytes(name) * cpath = path_b * cname = name_b # <<<<<<<<<<<<<< * * bufsize = size_guess */ __pyx_t_5 = __Pyx_PyObject_AsString(__pyx_v_name_b); if (unlikely((!__pyx_t_5) && PyErr_Occurred())) __PYX_ERR(3, 163, __pyx_L1_error) __pyx_v_cname = ((char *)__pyx_t_5); /* "src/fuse_api.pxi":165 * cname = name_b * * bufsize = size_guess # <<<<<<<<<<<<<< * buf = stdlib.malloc(bufsize * sizeof(char)) * */ __pyx_v_bufsize = __pyx_v_size_guess; /* "src/fuse_api.pxi":166 * * bufsize = size_guess * buf = stdlib.malloc(bufsize * sizeof(char)) # <<<<<<<<<<<<<< * * if buf is NULL: */ __pyx_v_buf = ((char *)malloc((__pyx_v_bufsize * (sizeof(char))))); /* "src/fuse_api.pxi":168 * buf = stdlib.malloc(bufsize * sizeof(char)) * * if buf is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ __pyx_t_3 = ((__pyx_v_buf == NULL) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":169 * * if buf is NULL: * cpython.exc.PyErr_NoMemory() # <<<<<<<<<<<<<< * * try: */ __pyx_t_6 = PyErr_NoMemory(); if (unlikely(__pyx_t_6 == NULL)) __PYX_ERR(3, 169, __pyx_L1_error) /* "src/fuse_api.pxi":168 * buf = stdlib.malloc(bufsize * sizeof(char)) * * if buf is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ } /* "src/fuse_api.pxi":171 * cpython.exc.PyErr_NoMemory() * * try: # <<<<<<<<<<<<<< * with nogil: * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) */ /*try:*/ { /* "src/fuse_api.pxi":172 * * try: * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":173 * try: * with nogil: * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) # <<<<<<<<<<<<<< * * if ret < 0 and errno.errno == errno.ERANGE: */ __pyx_v_ret = getxattr_p(__pyx_v_cpath, __pyx_v_cname, __pyx_v_buf, __pyx_v_bufsize, __pyx_v_cnamespace); } /* "src/fuse_api.pxi":172 * * try: * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L15; } __pyx_L15:; } } /* "src/fuse_api.pxi":175 * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * * if ret < 0 and errno.errno == errno.ERANGE: # <<<<<<<<<<<<<< * with nogil: * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) */ __pyx_t_2 = ((__pyx_v_ret < 0) != 0); if (__pyx_t_2) { } else { __pyx_t_3 = __pyx_t_2; goto __pyx_L17_bool_binop_done; } __pyx_t_2 = ((errno == ERANGE) != 0); __pyx_t_3 = __pyx_t_2; __pyx_L17_bool_binop_done:; if (__pyx_t_3) { /* "src/fuse_api.pxi":176 * * if ret < 0 and errno.errno == errno.ERANGE: * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) * if ret < 0: */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":177 * if ret < 0 and errno.errno == errno.ERANGE: * with nogil: * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) # <<<<<<<<<<<<<< * if ret < 0: * raise OSError(errno.errno, strerror(errno.errno), path) */ __pyx_v_ret = getxattr_p(__pyx_v_cpath, __pyx_v_cname, NULL, 0, __pyx_v_cnamespace); } /* "src/fuse_api.pxi":176 * * if ret < 0 and errno.errno == errno.ERANGE: * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) * if ret < 0: */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L21; } __pyx_L21:; } } /* "src/fuse_api.pxi":178 * with nogil: * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) * if ret < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * bufsize = ret */ __pyx_t_3 = ((__pyx_v_ret < 0) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":179 * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) * if ret < 0: * raise OSError(errno.errno, strerror(errno.errno), path) # <<<<<<<<<<<<<< * bufsize = ret * stdlib.free(buf) */ __pyx_t_1 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 179, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_4 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 179, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = PyTuple_New(3); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 179, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_1); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_4); __Pyx_INCREF(__pyx_v_path); __Pyx_GIVEREF(__pyx_v_path); PyTuple_SET_ITEM(__pyx_t_7, 2, __pyx_v_path); __pyx_t_1 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_7, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 179, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(3, 179, __pyx_L11_error) /* "src/fuse_api.pxi":178 * with nogil: * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) * if ret < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * bufsize = ret */ } /* "src/fuse_api.pxi":180 * if ret < 0: * raise OSError(errno.errno, strerror(errno.errno), path) * bufsize = ret # <<<<<<<<<<<<<< * stdlib.free(buf) * buf = stdlib.malloc(bufsize * sizeof(char)) */ __pyx_v_bufsize = ((size_t)__pyx_v_ret); /* "src/fuse_api.pxi":181 * raise OSError(errno.errno, strerror(errno.errno), path) * bufsize = ret * stdlib.free(buf) # <<<<<<<<<<<<<< * buf = stdlib.malloc(bufsize * sizeof(char)) * if buf is NULL: */ free(__pyx_v_buf); /* "src/fuse_api.pxi":182 * bufsize = ret * stdlib.free(buf) * buf = stdlib.malloc(bufsize * sizeof(char)) # <<<<<<<<<<<<<< * if buf is NULL: * cpython.exc.PyErr_NoMemory() */ __pyx_v_buf = ((char *)malloc((__pyx_v_bufsize * (sizeof(char))))); /* "src/fuse_api.pxi":183 * stdlib.free(buf) * buf = stdlib.malloc(bufsize * sizeof(char)) * if buf is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ __pyx_t_3 = ((__pyx_v_buf == NULL) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":184 * buf = stdlib.malloc(bufsize * sizeof(char)) * if buf is NULL: * cpython.exc.PyErr_NoMemory() # <<<<<<<<<<<<<< * * with nogil: */ __pyx_t_6 = PyErr_NoMemory(); if (unlikely(__pyx_t_6 == NULL)) __PYX_ERR(3, 184, __pyx_L11_error) /* "src/fuse_api.pxi":183 * stdlib.free(buf) * buf = stdlib.malloc(bufsize * sizeof(char)) * if buf is NULL: # <<<<<<<<<<<<<< * cpython.exc.PyErr_NoMemory() * */ } /* "src/fuse_api.pxi":186 * cpython.exc.PyErr_NoMemory() * * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":187 * * with nogil: * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) # <<<<<<<<<<<<<< * * if ret < 0: */ __pyx_v_ret = getxattr_p(__pyx_v_cpath, __pyx_v_cname, __pyx_v_buf, __pyx_v_bufsize, __pyx_v_cnamespace); } /* "src/fuse_api.pxi":186 * cpython.exc.PyErr_NoMemory() * * with nogil: # <<<<<<<<<<<<<< * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L26; } __pyx_L26:; } } /* "src/fuse_api.pxi":175 * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * * if ret < 0 and errno.errno == errno.ERANGE: # <<<<<<<<<<<<<< * with nogil: * ret = getxattr_p(cpath, cname, NULL, 0, cnamespace) */ } /* "src/fuse_api.pxi":189 * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * * if ret < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ __pyx_t_3 = ((__pyx_v_ret < 0) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":190 * * if ret < 0: * raise OSError(errno.errno, strerror(errno.errno), path) # <<<<<<<<<<<<<< * * return PyBytes_FromStringAndSize(buf, ret) */ __pyx_t_4 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 190, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 190, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 190, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_7); __Pyx_INCREF(__pyx_v_path); __Pyx_GIVEREF(__pyx_v_path); PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_path); __pyx_t_4 = 0; __pyx_t_7 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_1, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 190, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_7, 0, 0, 0); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __PYX_ERR(3, 190, __pyx_L11_error) /* "src/fuse_api.pxi":189 * ret = getxattr_p(cpath, cname, buf, bufsize, cnamespace) * * if ret < 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, strerror(errno.errno), path) * */ } /* "src/fuse_api.pxi":192 * raise OSError(errno.errno, strerror(errno.errno), path) * * return PyBytes_FromStringAndSize(buf, ret) # <<<<<<<<<<<<<< * * finally: */ __Pyx_XDECREF(__pyx_r); __pyx_t_7 = PyBytes_FromStringAndSize(__pyx_v_buf, __pyx_v_ret); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 192, __pyx_L11_error) __Pyx_GOTREF(__pyx_t_7); __pyx_r = __pyx_t_7; __pyx_t_7 = 0; goto __pyx_L10_return; } /* "src/fuse_api.pxi":195 * * finally: * stdlib.free(buf) # <<<<<<<<<<<<<< * * # Default options: */ /*finally:*/ { /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L11_error:; __pyx_t_11 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_14 = 0; __pyx_t_15 = 0; __pyx_t_16 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_14, &__pyx_t_15, &__pyx_t_16); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_11, &__pyx_t_12, &__pyx_t_13) < 0)) __Pyx_ErrFetch(&__pyx_t_11, &__pyx_t_12, &__pyx_t_13); __Pyx_XGOTREF(__pyx_t_11); __Pyx_XGOTREF(__pyx_t_12); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_16); __pyx_t_8 = __pyx_lineno; __pyx_t_9 = __pyx_clineno; __pyx_t_10 = __pyx_filename; { free(__pyx_v_buf); } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_XGIVEREF(__pyx_t_16); __Pyx_ExceptionReset(__pyx_t_14, __pyx_t_15, __pyx_t_16); } __Pyx_XGIVEREF(__pyx_t_11); __Pyx_XGIVEREF(__pyx_t_12); __Pyx_XGIVEREF(__pyx_t_13); __Pyx_ErrRestore(__pyx_t_11, __pyx_t_12, __pyx_t_13); __pyx_t_11 = 0; __pyx_t_12 = 0; __pyx_t_13 = 0; __pyx_t_14 = 0; __pyx_t_15 = 0; __pyx_t_16 = 0; __pyx_lineno = __pyx_t_8; __pyx_clineno = __pyx_t_9; __pyx_filename = __pyx_t_10; goto __pyx_L1_error; } __pyx_L10_return: { __pyx_t_16 = __pyx_r; __pyx_r = 0; free(__pyx_v_buf); __pyx_r = __pyx_t_16; __pyx_t_16 = 0; goto __pyx_L0; } } /* "src/fuse_api.pxi":117 * * * def getxattr(path, name, size_t size_guess=128, namespace='user'): # <<<<<<<<<<<<<< * '''Get extended attribute * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("llfuse.getxattr", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_path_b); __Pyx_XDECREF(__pyx_v_name_b); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":223 * 'no_splice_read', 'splice_write', 'splice_move')) * * def init(ops, mountpoint, options=default_options): # <<<<<<<<<<<<<< * '''Initialize and mount FUSE file system * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_9init(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_8init[] = "init(ops, mountpoint, options=default_options)\nInitialize and mount FUSE file system\n\n *ops* has to be an instance of the `Operations` class (or another\n class defining the same methods).\n\n *args* has to be a set of strings. `default_options` provides some\n reasonable defaults. It is recommended to use these options as a basis and\n add or remove options as necessary. For example::\n\n my_opts = set(llfuse.default_options)\n my_opts.add('allow_other')\n my_opts.discard('default_permissions')\n llfuse.init(ops, mountpoint, my_opts)\n\n Valid options are listed under ``struct\n fuse_opt fuse_mount_opts[]``\n (`mount.c:82 `_)\n and ``struct fuse_opt fuse_ll_opts[]``\n (`fuse_lowlevel_c:2626 `_).\n "; static PyMethodDef __pyx_mdef_6llfuse_9init = {"init", (PyCFunction)__pyx_pw_6llfuse_9init, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_8init}; static PyObject *__pyx_pw_6llfuse_9init(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_ops = 0; PyObject *__pyx_v_mountpoint = 0; PyObject *__pyx_v_options = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("init (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_ops,&__pyx_n_s_mountpoint,&__pyx_n_s_options,0}; PyObject* values[3] = {0,0,0}; values[2] = __pyx_k__65; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_ops)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_mountpoint)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("init", 0, 2, 3, 1); __PYX_ERR(3, 223, __pyx_L3_error) } case 2: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_options); if (value) { values[2] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "init") < 0)) __PYX_ERR(3, 223, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[0] = PyTuple_GET_ITEM(__pyx_args, 0); break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_ops = values[0]; __pyx_v_mountpoint = values[1]; __pyx_v_options = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("init", 0, 2, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 223, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.init", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_8init(__pyx_self, __pyx_v_ops, __pyx_v_mountpoint, __pyx_v_options); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_8init(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_ops, PyObject *__pyx_v_mountpoint, PyObject *__pyx_v_options) { struct fuse_args __pyx_v_f_args; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; int __pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; char *__pyx_t_7; __Pyx_RefNannySetupContext("init", 0); /* "src/fuse_api.pxi":245 * ''' * * log.debug('Initializing llfuse') # <<<<<<<<<<<<<< * cdef fuse_args f_args * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__66, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":248 * cdef fuse_args f_args * * if not isinstance(mountpoint, str_t): # <<<<<<<<<<<<<< * raise TypeError('*mountpoint_* argument must be of type str') * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_str_t); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 248, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyObject_IsInstance(__pyx_v_mountpoint, __pyx_t_1); if (unlikely(__pyx_t_3 == -1)) __PYX_ERR(3, 248, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_4 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_4) { /* "src/fuse_api.pxi":249 * * if not isinstance(mountpoint, str_t): * raise TypeError('*mountpoint_* argument must be of type str') # <<<<<<<<<<<<<< * * global operations */ __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__67, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 249, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 249, __pyx_L1_error) /* "src/fuse_api.pxi":248 * cdef fuse_args f_args * * if not isinstance(mountpoint, str_t): # <<<<<<<<<<<<<< * raise TypeError('*mountpoint_* argument must be of type str') * */ } /* "src/fuse_api.pxi":257 * global channel * * mountpoint_b = str2bytes(os.path.abspath(mountpoint)) # <<<<<<<<<<<<<< * operations = ops * */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_path); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_abspath); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (!__pyx_t_5) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v_mountpoint); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_v_mountpoint}; __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_5, __pyx_v_mountpoint}; __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { __pyx_t_6 = PyTuple_New(1+1); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_5); __pyx_t_5 = NULL; __Pyx_INCREF(__pyx_v_mountpoint); __Pyx_GIVEREF(__pyx_v_mountpoint); PyTuple_SET_ITEM(__pyx_t_6, 0+1, __pyx_v_mountpoint); __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_6, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; } } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __pyx_f_6llfuse_str2bytes(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 257, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XGOTREF(__pyx_v_6llfuse_mountpoint_b); __Pyx_DECREF_SET(__pyx_v_6llfuse_mountpoint_b, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":258 * * mountpoint_b = str2bytes(os.path.abspath(mountpoint)) * operations = ops # <<<<<<<<<<<<<< * * make_fuse_args(options, &f_args) */ __Pyx_INCREF(__pyx_v_ops); __Pyx_XGOTREF(__pyx_v_6llfuse_operations); __Pyx_DECREF_SET(__pyx_v_6llfuse_operations, __pyx_v_ops); __Pyx_GIVEREF(__pyx_v_ops); /* "src/fuse_api.pxi":260 * operations = ops * * make_fuse_args(options, &f_args) # <<<<<<<<<<<<<< * log.debug('Calling fuse_mount') * channel = fuse_mount(mountpoint_b, &f_args) */ __pyx_t_2 = __pyx_f_6llfuse_make_fuse_args(__pyx_v_options, (&__pyx_v_f_args)); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 260, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":261 * * make_fuse_args(options, &f_args) * log.debug('Calling fuse_mount') # <<<<<<<<<<<<<< * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_debug); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__68, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":262 * make_fuse_args(options, &f_args) * log.debug('Calling fuse_mount') * channel = fuse_mount(mountpoint_b, &f_args) # <<<<<<<<<<<<<< * if not channel: * raise RuntimeError('fuse_mount failed') */ __pyx_t_7 = __Pyx_PyObject_AsString(__pyx_v_6llfuse_mountpoint_b); if (unlikely((!__pyx_t_7) && PyErr_Occurred())) __PYX_ERR(3, 262, __pyx_L1_error) __pyx_v_6llfuse_channel = fuse_mount(((char *)__pyx_t_7), (&__pyx_v_f_args)); /* "src/fuse_api.pxi":263 * log.debug('Calling fuse_mount') * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: # <<<<<<<<<<<<<< * raise RuntimeError('fuse_mount failed') * */ __pyx_t_4 = ((!(__pyx_v_6llfuse_channel != 0)) != 0); if (__pyx_t_4) { /* "src/fuse_api.pxi":264 * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: * raise RuntimeError('fuse_mount failed') # <<<<<<<<<<<<<< * * log.debug('Calling fuse_lowlevel_new') */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__69, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(3, 264, __pyx_L1_error) /* "src/fuse_api.pxi":263 * log.debug('Calling fuse_mount') * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: # <<<<<<<<<<<<<< * raise RuntimeError('fuse_mount failed') * */ } /* "src/fuse_api.pxi":266 * raise RuntimeError('fuse_mount failed') * * log.debug('Calling fuse_lowlevel_new') # <<<<<<<<<<<<<< * init_fuse_ops() * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_debug); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__70, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":267 * * log.debug('Calling fuse_lowlevel_new') * init_fuse_ops() # <<<<<<<<<<<<<< * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) * if not session: */ __pyx_f_6llfuse_init_fuse_ops(); /* "src/fuse_api.pxi":268 * log.debug('Calling fuse_lowlevel_new') * init_fuse_ops() * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) # <<<<<<<<<<<<<< * if not session: * fuse_unmount(mountpoint_b, channel) */ __pyx_v_6llfuse_session = fuse_lowlevel_new((&__pyx_v_f_args), (&__pyx_v_6llfuse_fuse_ops), (sizeof(__pyx_v_6llfuse_fuse_ops)), NULL); /* "src/fuse_api.pxi":269 * init_fuse_ops() * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) * if not session: # <<<<<<<<<<<<<< * fuse_unmount(mountpoint_b, channel) * raise RuntimeError("fuse_lowlevel_new() failed") */ __pyx_t_4 = ((!(__pyx_v_6llfuse_session != 0)) != 0); if (__pyx_t_4) { /* "src/fuse_api.pxi":270 * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) * if not session: * fuse_unmount(mountpoint_b, channel) # <<<<<<<<<<<<<< * raise RuntimeError("fuse_lowlevel_new() failed") * */ __pyx_t_7 = __Pyx_PyObject_AsString(__pyx_v_6llfuse_mountpoint_b); if (unlikely((!__pyx_t_7) && PyErr_Occurred())) __PYX_ERR(3, 270, __pyx_L1_error) fuse_unmount(((char *)__pyx_t_7), __pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":271 * if not session: * fuse_unmount(mountpoint_b, channel) * raise RuntimeError("fuse_lowlevel_new() failed") # <<<<<<<<<<<<<< * * log.debug('Calling fuse_session_add_chan') */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__71, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 271, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(3, 271, __pyx_L1_error) /* "src/fuse_api.pxi":269 * init_fuse_ops() * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) * if not session: # <<<<<<<<<<<<<< * fuse_unmount(mountpoint_b, channel) * raise RuntimeError("fuse_lowlevel_new() failed") */ } /* "src/fuse_api.pxi":273 * raise RuntimeError("fuse_lowlevel_new() failed") * * log.debug('Calling fuse_session_add_chan') # <<<<<<<<<<<<<< * fuse_session_add_chan(session, channel) * */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_debug); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__72, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":274 * * log.debug('Calling fuse_session_add_chan') * fuse_session_add_chan(session, channel) # <<<<<<<<<<<<<< * * pthread_mutex_init(&exc_info_mutex, NULL) */ fuse_session_add_chan(__pyx_v_6llfuse_session, __pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":276 * fuse_session_add_chan(session, channel) * * pthread_mutex_init(&exc_info_mutex, NULL) # <<<<<<<<<<<<<< * * def main(workers=None): */ pthread_mutex_init((&__pyx_v_6llfuse_exc_info_mutex), NULL); /* "src/fuse_api.pxi":223 * 'no_splice_read', 'splice_write', 'splice_move')) * * def init(ops, mountpoint, options=default_options): # <<<<<<<<<<<<<< * '''Initialize and mount FUSE file system * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_AddTraceback("llfuse.init", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":278 * pthread_mutex_init(&exc_info_mutex, NULL) * * def main(workers=None): # <<<<<<<<<<<<<< * '''Run FUSE main loop * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_11main(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_10main[] = "main(workers=None)\nRun FUSE main loop\n\n *workers* specifies the number of threads that will process requests\n concurrently. If *workers* is `None`, llfuse will pick a reasonable\n number bigger than one. If *workers* is ``1`` all requests will be\n processed by the thread calling `main`.\n\n This function will also start additional threads for internal purposes (even\n if *workers* is ``1``). These (and all worker threads) are guaranteed to\n have terminated when `main` returns.\n\n While this function is running, special signal handlers will be installed\n for the *SIGTERM*, *SIGINT* (Ctrl-C), *SIGHUP*, *SIGUSR1* and *SIGPIPE*\n signals. *SIGPIPE* will be ignored, while the other three signals will cause\n request processing to stop and the function to return. *SIGINT* (Ctrl-C)\n will thus *not* result in a `KeyboardInterrupt` exception while this\n function is runnning.\n\n When the function returns because the file system has received an unmount\n request it will return `None`. If it returns because it has received a\n signal, it will return the signal number.\n "; static PyMethodDef __pyx_mdef_6llfuse_11main = {"main", (PyCFunction)__pyx_pw_6llfuse_11main, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_10main}; static PyObject *__pyx_pw_6llfuse_11main(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_workers = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("main (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_workers,0}; PyObject* values[1] = {0}; values[0] = ((PyObject *)Py_None); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_workers); if (value) { values[0] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "main") < 0)) __PYX_ERR(3, 278, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_workers = values[0]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("main", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 278, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.main", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_10main(__pyx_self, __pyx_v_workers); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":320 * with contextlib.ExitStack() as on_exit: * set_signal_handlers() * on_exit.callback(lambda: restore_signal_handlers()) # <<<<<<<<<<<<<< * * # Start notification handling thread */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4main_lambda(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static PyMethodDef __pyx_mdef_6llfuse_4main_lambda = {"lambda", (PyCFunction)__pyx_pw_6llfuse_4main_lambda, METH_NOARGS, 0}; static PyObject *__pyx_pw_6llfuse_4main_lambda(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("lambda (wrapper)", 0); __pyx_r = __pyx_lambda_funcdef_lambda(__pyx_self); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_lambda_funcdef_lambda(CYTHON_UNUSED PyObject *__pyx_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("lambda", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __pyx_f_6llfuse_restore_signal_handlers(); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 320, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.main.lambda", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":328 * on_exit.callback(_notify_queue.put, None, block=True, timeout=5) * * on_exit.callback(lambda: fuse_session_reset(session)) # <<<<<<<<<<<<<< * exc_info = None * log.debug('Calling fuse_session_loop') */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_4main_1lambda1(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static PyMethodDef __pyx_mdef_6llfuse_4main_1lambda1 = {"lambda1", (PyCFunction)__pyx_pw_6llfuse_4main_1lambda1, METH_NOARGS, 0}; static PyObject *__pyx_pw_6llfuse_4main_1lambda1(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("lambda1 (wrapper)", 0); __pyx_r = __pyx_lambda_funcdef_lambda1(__pyx_self); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_lambda_funcdef_lambda1(CYTHON_UNUSED PyObject *__pyx_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("lambda1", 0); __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_void_to_None(fuse_session_reset(__pyx_v_6llfuse_session)); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 328, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.main.lambda1", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":278 * pthread_mutex_init(&exc_info_mutex, NULL) * * def main(workers=None): # <<<<<<<<<<<<<< * '''Run FUSE main loop * */ static PyObject *__pyx_pf_6llfuse_10main(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_workers) { PyObject *__pyx_v_on_exit = NULL; PyObject *__pyx_v_t = NULL; PyObject *__pyx_v_tmp = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; PyObject *__pyx_t_12 = NULL; __Pyx_RefNannySetupContext("main", 0); __Pyx_INCREF(__pyx_v_workers); /* "src/fuse_api.pxi":305 * global exit_reason * * if session == NULL: # <<<<<<<<<<<<<< * raise RuntimeError('Need to call init() before main()') * */ __pyx_t_1 = ((__pyx_v_6llfuse_session == NULL) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":306 * * if session == NULL: * raise RuntimeError('Need to call init() before main()') # <<<<<<<<<<<<<< * * if workers == 0: */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_tuple__73, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 306, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(3, 306, __pyx_L1_error) /* "src/fuse_api.pxi":305 * global exit_reason * * if session == NULL: # <<<<<<<<<<<<<< * raise RuntimeError('Need to call init() before main()') * */ } /* "src/fuse_api.pxi":308 * raise RuntimeError('Need to call init() before main()') * * if workers == 0: # <<<<<<<<<<<<<< * raise ValueError('No workers is not a good idea') * */ __pyx_t_2 = __Pyx_PyInt_EqObjC(__pyx_v_workers, __pyx_int_0, 0, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 308, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(3, 308, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_1) { /* "src/fuse_api.pxi":309 * * if workers == 0: * raise ValueError('No workers is not a good idea') # <<<<<<<<<<<<<< * * if workers is None: */ __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__74, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 309, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(3, 309, __pyx_L1_error) /* "src/fuse_api.pxi":308 * raise RuntimeError('Need to call init() before main()') * * if workers == 0: # <<<<<<<<<<<<<< * raise ValueError('No workers is not a good idea') * */ } /* "src/fuse_api.pxi":311 * raise ValueError('No workers is not a good idea') * * if workers is None: # <<<<<<<<<<<<<< * # We may add some smartness here later. * workers = 30 */ __pyx_t_1 = (__pyx_v_workers == Py_None); __pyx_t_3 = (__pyx_t_1 != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":313 * if workers is None: * # We may add some smartness here later. * workers = 30 # <<<<<<<<<<<<<< * * # SIGKILL cannot be caught, so we can use it as a placeholder */ __Pyx_INCREF(__pyx_int_30); __Pyx_DECREF_SET(__pyx_v_workers, __pyx_int_30); /* "src/fuse_api.pxi":311 * raise ValueError('No workers is not a good idea') * * if workers is None: # <<<<<<<<<<<<<< * # We may add some smartness here later. * workers = 30 */ } /* "src/fuse_api.pxi":317 * # SIGKILL cannot be caught, so we can use it as a placeholder * # for "regular exit". * exit_reason = signal.SIGKILL # <<<<<<<<<<<<<< * with contextlib.ExitStack() as on_exit: * set_signal_handlers() */ __pyx_v_6llfuse_exit_reason = SIGKILL; /* "src/fuse_api.pxi":318 * # for "regular exit". * exit_reason = signal.SIGKILL * with contextlib.ExitStack() as on_exit: # <<<<<<<<<<<<<< * set_signal_handlers() * on_exit.callback(lambda: restore_signal_handlers()) */ /*with:*/ { __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_contextlib); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_ExitStack); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_5); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_5, function); } } if (__pyx_t_4) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 318, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_6 = __Pyx_PyObject_LookupSpecial(__pyx_t_2, __pyx_n_s_exit); if (unlikely(!__pyx_t_6)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_6); __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_2, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 318, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_7) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_7); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 318, __pyx_L6_error) __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } else { __pyx_t_5 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 318, __pyx_L6_error) } __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_t_5; __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_8, &__pyx_t_9, &__pyx_t_10); __Pyx_XGOTREF(__pyx_t_8); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); /*try:*/ { __pyx_v_on_exit = __pyx_t_4; __pyx_t_4 = 0; /* "src/fuse_api.pxi":319 * exit_reason = signal.SIGKILL * with contextlib.ExitStack() as on_exit: * set_signal_handlers() # <<<<<<<<<<<<<< * on_exit.callback(lambda: restore_signal_handlers()) * */ __pyx_t_4 = __pyx_f_6llfuse_set_signal_handlers(); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 319, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/fuse_api.pxi":320 * with contextlib.ExitStack() as on_exit: * set_signal_handlers() * on_exit.callback(lambda: restore_signal_handlers()) # <<<<<<<<<<<<<< * * # Start notification handling thread */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_on_exit, __pyx_n_s_callback); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_4main_lambda, 0, __pyx_n_s_main_locals_lambda, NULL, __pyx_n_s_llfuse, __pyx_d, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_7 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_7)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_7); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (!__pyx_t_7) { __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_5); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_GOTREF(__pyx_t_4); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_t_5}; __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_7, __pyx_t_5}; __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else #endif { __pyx_t_11 = PyTuple_New(1+1); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_7); __pyx_t_7 = NULL; __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_11, 0+1, __pyx_t_5); __pyx_t_5 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_11, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 320, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/fuse_api.pxi":323 * * # Start notification handling thread * t = threading.Thread(target=_notify_loop) # <<<<<<<<<<<<<< * t.daemon = True * t.start() */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_threading); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_Thread); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_11 = __Pyx_GetModuleGlobalName(__pyx_n_s_notify_loop); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_11); if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_target, __pyx_t_11) < 0) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __pyx_t_11 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_4); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 323, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_v_t = __pyx_t_11; __pyx_t_11 = 0; /* "src/fuse_api.pxi":324 * # Start notification handling thread * t = threading.Thread(target=_notify_loop) * t.daemon = True # <<<<<<<<<<<<<< * t.start() * on_exit.callback(_notify_queue.put, None, block=True, timeout=5) */ if (__Pyx_PyObject_SetAttrStr(__pyx_v_t, __pyx_n_s_daemon, Py_True) < 0) __PYX_ERR(3, 324, __pyx_L10_error) /* "src/fuse_api.pxi":325 * t = threading.Thread(target=_notify_loop) * t.daemon = True * t.start() # <<<<<<<<<<<<<< * on_exit.callback(_notify_queue.put, None, block=True, timeout=5) * */ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_t, __pyx_n_s_start); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 325, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_2)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_2) { __pyx_t_11 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_2); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 325, __pyx_L10_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else { __pyx_t_11 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 325, __pyx_L10_error) } __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; /* "src/fuse_api.pxi":326 * t.daemon = True * t.start() * on_exit.callback(_notify_queue.put, None, block=True, timeout=5) # <<<<<<<<<<<<<< * * on_exit.callback(lambda: fuse_session_reset(session)) */ __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_v_on_exit, __pyx_n_s_callback); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 326, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse__notify_queue, __pyx_n_s_put); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 326, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 326, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_4); __Pyx_INCREF(Py_None); __Pyx_GIVEREF(Py_None); PyTuple_SET_ITEM(__pyx_t_2, 1, Py_None); __pyx_t_4 = 0; __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 326, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_block, Py_True) < 0) __PYX_ERR(3, 326, __pyx_L10_error) if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_timeout, __pyx_int_5) < 0) __PYX_ERR(3, 326, __pyx_L10_error) __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_11, __pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 326, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/fuse_api.pxi":328 * on_exit.callback(_notify_queue.put, None, block=True, timeout=5) * * on_exit.callback(lambda: fuse_session_reset(session)) # <<<<<<<<<<<<<< * exc_info = None * log.debug('Calling fuse_session_loop') */ __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_on_exit, __pyx_n_s_callback); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_4main_1lambda1, 0, __pyx_n_s_main_locals_lambda, NULL, __pyx_n_s_llfuse, __pyx_d, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_11 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_11)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_11); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (!__pyx_t_11) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_5); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[2] = {__pyx_t_11, __pyx_t_2}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[2] = {__pyx_t_11, __pyx_t_2}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else #endif { __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_11); __pyx_t_11 = NULL; __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_t_2); __pyx_t_2 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 328, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/fuse_api.pxi":329 * * on_exit.callback(lambda: fuse_session_reset(session)) * exc_info = None # <<<<<<<<<<<<<< * log.debug('Calling fuse_session_loop') * if workers == 1: */ __Pyx_INCREF(Py_None); __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, Py_None); __Pyx_GIVEREF(Py_None); /* "src/fuse_api.pxi":330 * on_exit.callback(lambda: fuse_session_reset(session)) * exc_info = None * log.debug('Calling fuse_session_loop') # <<<<<<<<<<<<<< * if workers == 1: * session_loop_single() */ __pyx_t_5 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 330, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_5, __pyx_n_s_debug); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 330, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__75, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 330, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/fuse_api.pxi":331 * exc_info = None * log.debug('Calling fuse_session_loop') * if workers == 1: # <<<<<<<<<<<<<< * session_loop_single() * else: */ __pyx_t_5 = __Pyx_PyInt_EqObjC(__pyx_v_workers, __pyx_int_1, 1, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 331, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 331, __pyx_L10_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (__pyx_t_3) { /* "src/fuse_api.pxi":332 * log.debug('Calling fuse_session_loop') * if workers == 1: * session_loop_single() # <<<<<<<<<<<<<< * else: * session_loop_mt(workers) */ __pyx_t_5 = __pyx_f_6llfuse_session_loop_single(); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 332, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/fuse_api.pxi":331 * exc_info = None * log.debug('Calling fuse_session_loop') * if workers == 1: # <<<<<<<<<<<<<< * session_loop_single() * else: */ goto __pyx_L18; } /* "src/fuse_api.pxi":334 * session_loop_single() * else: * session_loop_mt(workers) # <<<<<<<<<<<<<< * * if exc_info: */ /*else*/ { __pyx_t_5 = __pyx_f_6llfuse_session_loop_mt(__pyx_v_workers); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 334, __pyx_L10_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } __pyx_L18:; /* "src/fuse_api.pxi":318 * # for "regular exit". * exit_reason = signal.SIGKILL * with contextlib.ExitStack() as on_exit: # <<<<<<<<<<<<<< * set_signal_handlers() * on_exit.callback(lambda: restore_signal_handlers()) */ } __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; goto __pyx_L17_try_end; __pyx_L10_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.main", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_4, &__pyx_t_7) < 0) __PYX_ERR(3, 318, __pyx_L12_except_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_7); __pyx_t_2 = PyTuple_Pack(3, __pyx_t_5, __pyx_t_4, __pyx_t_7); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 318, __pyx_L12_except_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_2, NULL); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 318, __pyx_L12_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (__pyx_t_3 < 0) __PYX_ERR(3, 318, __pyx_L12_except_error) __pyx_t_1 = ((!(__pyx_t_3 != 0)) != 0); if (__pyx_t_1) { __Pyx_GIVEREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_ErrRestoreWithState(__pyx_t_5, __pyx_t_4, __pyx_t_7); __pyx_t_5 = 0; __pyx_t_4 = 0; __pyx_t_7 = 0; __PYX_ERR(3, 318, __pyx_L12_except_error) } __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; goto __pyx_L11_exception_handled; } __pyx_L12_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_8); __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10); goto __pyx_L1_error; __pyx_L11_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_8); __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_ExceptionReset(__pyx_t_8, __pyx_t_9, __pyx_t_10); __pyx_L17_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_6) { __pyx_t_10 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_tuple__76, NULL); __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } goto __pyx_L9; } __pyx_L9:; } goto __pyx_L22; __pyx_L6_error:; __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L1_error; __pyx_L22:; } /* "src/fuse_api.pxi":336 * session_loop_mt(workers) * * if exc_info: # <<<<<<<<<<<<<< * # Re-raise expression from request handler * log.debug('Terminated main loop because request handler raised exception, re-raising..') */ __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_6llfuse_exc_info); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(3, 336, __pyx_L1_error) if (__pyx_t_1) { /* "src/fuse_api.pxi":338 * if exc_info: * # Re-raise expression from request handler * log.debug('Terminated main loop because request handler raised exception, re-raising..') # <<<<<<<<<<<<<< * tmp = exc_info * exc_info = None */ __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 338, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_debug); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 338, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple__77, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 338, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/fuse_api.pxi":339 * # Re-raise expression from request handler * log.debug('Terminated main loop because request handler raised exception, re-raising..') * tmp = exc_info # <<<<<<<<<<<<<< * exc_info = None * */ __Pyx_INCREF(__pyx_v_6llfuse_exc_info); __pyx_v_tmp = __pyx_v_6llfuse_exc_info; /* "src/fuse_api.pxi":340 * log.debug('Terminated main loop because request handler raised exception, re-raising..') * tmp = exc_info * exc_info = None # <<<<<<<<<<<<<< * * # The explicit version check works around a Cython bug with */ __Pyx_INCREF(Py_None); __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, Py_None); __Pyx_GIVEREF(Py_None); /* "src/fuse_api.pxi":345 * # the 3-parameter version of the raise statement, c.f. * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * raise tmp[0], tmp[1], tmp[2] * else: */ __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":346 * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: * raise tmp[0], tmp[1], tmp[2] # <<<<<<<<<<<<<< * else: * raise tmp[1].with_traceback(tmp[2]) */ __pyx_t_7 = __Pyx_GetItemInt(__pyx_v_tmp, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 346, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_tmp, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 346, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_tmp, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 346, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_Raise(__pyx_t_7, __pyx_t_4, __pyx_t_5, 0); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(3, 346, __pyx_L1_error) /* "src/fuse_api.pxi":345 * # the 3-parameter version of the raise statement, c.f. * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * raise tmp[0], tmp[1], tmp[2] * else: */ } /* "src/fuse_api.pxi":348 * raise tmp[0], tmp[1], tmp[2] * else: * raise tmp[1].with_traceback(tmp[2]) # <<<<<<<<<<<<<< * * if exit_reason == signal.SIGKILL: */ /*else*/ { __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_tmp, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_with_traceback); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __Pyx_GetItemInt(__pyx_v_tmp, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_7); if (likely(__pyx_t_2)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7); __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_7, function); } } if (!__pyx_t_2) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_5); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[2] = {__pyx_t_2, __pyx_t_4}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) { PyObject *__pyx_temp[2] = {__pyx_t_2, __pyx_t_4}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_11 = PyTuple_New(1+1); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_2); __pyx_t_2 = NULL; __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_11, 0+1, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_11, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 348, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } } __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_Raise(__pyx_t_5, 0, 0, 0); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(3, 348, __pyx_L1_error) } /* "src/fuse_api.pxi":336 * session_loop_mt(workers) * * if exc_info: # <<<<<<<<<<<<<< * # Re-raise expression from request handler * log.debug('Terminated main loop because request handler raised exception, re-raising..') */ } /* "src/fuse_api.pxi":350 * raise tmp[1].with_traceback(tmp[2]) * * if exit_reason == signal.SIGKILL: # <<<<<<<<<<<<<< * return None * else: */ __pyx_t_1 = ((__pyx_v_6llfuse_exit_reason == SIGKILL) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":351 * * if exit_reason == signal.SIGKILL: * return None # <<<<<<<<<<<<<< * else: * return exit_reason */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(Py_None); __pyx_r = Py_None; goto __pyx_L0; /* "src/fuse_api.pxi":350 * raise tmp[1].with_traceback(tmp[2]) * * if exit_reason == signal.SIGKILL: # <<<<<<<<<<<<<< * return None * else: */ } /* "src/fuse_api.pxi":353 * return None * else: * return exit_reason # <<<<<<<<<<<<<< * * cdef session_loop_single(): */ /*else*/ { __Pyx_XDECREF(__pyx_r); __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_6llfuse_exit_reason); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 353, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __pyx_r = __pyx_t_5; __pyx_t_5 = 0; goto __pyx_L0; } /* "src/fuse_api.pxi":278 * pthread_mutex_init(&exc_info_mutex, NULL) * * def main(workers=None): # <<<<<<<<<<<<<< * '''Run FUSE main loop * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_11); __Pyx_AddTraceback("llfuse.main", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_on_exit); __Pyx_XDECREF(__pyx_v_t); __Pyx_XDECREF(__pyx_v_tmp); __Pyx_XDECREF(__pyx_v_workers); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":355 * return exit_reason * * cdef session_loop_single(): # <<<<<<<<<<<<<< * cdef void* mem * cdef size_t size */ static PyObject *__pyx_f_6llfuse_session_loop_single(void) { void *__pyx_v_mem; size_t __pyx_v_size; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations void *__pyx_t_1; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; int __pyx_t_4; char const *__pyx_t_5; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; PyObject *__pyx_t_11 = NULL; __Pyx_RefNannySetupContext("session_loop_single", 0); /* "src/fuse_api.pxi":359 * cdef size_t size * * size = fuse_chan_bufsize(channel) # <<<<<<<<<<<<<< * mem = calloc_or_raise(1, size) * try: */ __pyx_v_size = fuse_chan_bufsize(__pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":360 * * size = fuse_chan_bufsize(channel) * mem = calloc_or_raise(1, size) # <<<<<<<<<<<<<< * try: * session_loop(mem, size) */ __pyx_t_1 = __pyx_f_6llfuse_calloc_or_raise(1, __pyx_v_size); if (unlikely(__pyx_t_1 == NULL)) __PYX_ERR(3, 360, __pyx_L1_error) __pyx_v_mem = __pyx_t_1; /* "src/fuse_api.pxi":361 * size = fuse_chan_bufsize(channel) * mem = calloc_or_raise(1, size) * try: # <<<<<<<<<<<<<< * session_loop(mem, size) * finally: */ /*try:*/ { /* "src/fuse_api.pxi":362 * mem = calloc_or_raise(1, size) * try: * session_loop(mem, size) # <<<<<<<<<<<<<< * finally: * stdlib.free(mem) */ __pyx_t_2 = __pyx_f_6llfuse_session_loop(__pyx_v_mem, __pyx_v_size); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 362, __pyx_L4_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } /* "src/fuse_api.pxi":364 * session_loop(mem, size) * finally: * stdlib.free(mem) # <<<<<<<<<<<<<< * * cdef session_loop(void* mem, size_t size): */ /*finally:*/ { /*normal exit:*/{ free(__pyx_v_mem); goto __pyx_L5; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L4_error:; __pyx_t_6 = 0; __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_9, &__pyx_t_10, &__pyx_t_11); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8) < 0)) __Pyx_ErrFetch(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8); __Pyx_XGOTREF(__pyx_t_6); __Pyx_XGOTREF(__pyx_t_7); __Pyx_XGOTREF(__pyx_t_8); __Pyx_XGOTREF(__pyx_t_9); __Pyx_XGOTREF(__pyx_t_10); __Pyx_XGOTREF(__pyx_t_11); __pyx_t_3 = __pyx_lineno; __pyx_t_4 = __pyx_clineno; __pyx_t_5 = __pyx_filename; { free(__pyx_v_mem); } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_9); __Pyx_XGIVEREF(__pyx_t_10); __Pyx_XGIVEREF(__pyx_t_11); __Pyx_ExceptionReset(__pyx_t_9, __pyx_t_10, __pyx_t_11); } __Pyx_XGIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_8); __Pyx_ErrRestore(__pyx_t_6, __pyx_t_7, __pyx_t_8); __pyx_t_6 = 0; __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_lineno = __pyx_t_3; __pyx_clineno = __pyx_t_4; __pyx_filename = __pyx_t_5; goto __pyx_L1_error; } __pyx_L5:; } /* "src/fuse_api.pxi":355 * return exit_reason * * cdef session_loop_single(): # <<<<<<<<<<<<<< * cdef void* mem * cdef size_t size */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_AddTraceback("llfuse.session_loop_single", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":366 * stdlib.free(mem) * * cdef session_loop(void* mem, size_t size): # <<<<<<<<<<<<<< * '''Process requests''' * */ static PyObject *__pyx_f_6llfuse_session_loop(void *__pyx_v_mem, size_t __pyx_v_size) { int __pyx_v_res; struct fuse_chan *__pyx_v_ch; struct fuse_buf __pyx_v_buf; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; __Pyx_RefNannySetupContext("session_loop", 0); /* "src/fuse_api.pxi":373 * cdef fuse_buf buf * * while not fuse_session_exited(session): # <<<<<<<<<<<<<< * ch = channel * buf.mem = mem */ while (1) { __pyx_t_1 = ((!(fuse_session_exited(__pyx_v_6llfuse_session) != 0)) != 0); if (!__pyx_t_1) break; /* "src/fuse_api.pxi":374 * * while not fuse_session_exited(session): * ch = channel # <<<<<<<<<<<<<< * buf.mem = mem * buf.size = size */ __pyx_v_ch = __pyx_v_6llfuse_channel; /* "src/fuse_api.pxi":375 * while not fuse_session_exited(session): * ch = channel * buf.mem = mem # <<<<<<<<<<<<<< * buf.size = size * buf.pos = 0 */ __pyx_v_buf.mem = __pyx_v_mem; /* "src/fuse_api.pxi":376 * ch = channel * buf.mem = mem * buf.size = size # <<<<<<<<<<<<<< * buf.pos = 0 * buf.flags = 0 */ __pyx_v_buf.size = __pyx_v_size; /* "src/fuse_api.pxi":377 * buf.mem = mem * buf.size = size * buf.pos = 0 # <<<<<<<<<<<<<< * buf.flags = 0 * with nogil: */ __pyx_v_buf.pos = 0; /* "src/fuse_api.pxi":378 * buf.size = size * buf.pos = 0 * buf.flags = 0 # <<<<<<<<<<<<<< * with nogil: * res = fuse_session_receive_buf(session, &buf, &ch) */ __pyx_v_buf.flags = 0; /* "src/fuse_api.pxi":379 * buf.pos = 0 * buf.flags = 0 * with nogil: # <<<<<<<<<<<<<< * res = fuse_session_receive_buf(session, &buf, &ch) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":380 * buf.flags = 0 * with nogil: * res = fuse_session_receive_buf(session, &buf, &ch) # <<<<<<<<<<<<<< * * if res == -errno.EINTR: */ __pyx_v_res = fuse_session_receive_buf(__pyx_v_6llfuse_session, (&__pyx_v_buf), (&__pyx_v_ch)); } /* "src/fuse_api.pxi":379 * buf.pos = 0 * buf.flags = 0 * with nogil: # <<<<<<<<<<<<<< * res = fuse_session_receive_buf(session, &buf, &ch) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L9; } __pyx_L9:; } } /* "src/fuse_api.pxi":382 * res = fuse_session_receive_buf(session, &buf, &ch) * * if res == -errno.EINTR: # <<<<<<<<<<<<<< * continue * elif res < 0: */ __pyx_t_1 = ((__pyx_v_res == (-EINTR)) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":383 * * if res == -errno.EINTR: * continue # <<<<<<<<<<<<<< * elif res < 0: * raise OSError(-res, 'fuse_session_receive_buf failed with ' */ goto __pyx_L3_continue; /* "src/fuse_api.pxi":382 * res = fuse_session_receive_buf(session, &buf, &ch) * * if res == -errno.EINTR: # <<<<<<<<<<<<<< * continue * elif res < 0: */ } /* "src/fuse_api.pxi":384 * if res == -errno.EINTR: * continue * elif res < 0: # <<<<<<<<<<<<<< * raise OSError(-res, 'fuse_session_receive_buf failed with ' * + strerror(-res)) */ __pyx_t_1 = ((__pyx_v_res < 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":385 * continue * elif res < 0: * raise OSError(-res, 'fuse_session_receive_buf failed with ' # <<<<<<<<<<<<<< * + strerror(-res)) * elif res == 0: */ __pyx_t_2 = __Pyx_PyInt_From_int((-__pyx_v_res)); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); /* "src/fuse_api.pxi":386 * elif res < 0: * raise OSError(-res, 'fuse_session_receive_buf failed with ' * + strerror(-res)) # <<<<<<<<<<<<<< * elif res == 0: * break */ __pyx_t_3 = __pyx_f_6llfuse_strerror((-__pyx_v_res)); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 386, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = PyNumber_Add(__pyx_kp_u_fuse_session_receive_buf_failed, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 386, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/fuse_api.pxi":385 * continue * elif res < 0: * raise OSError(-res, 'fuse_session_receive_buf failed with ' # <<<<<<<<<<<<<< * + strerror(-res)) * elif res == 0: */ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 385, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(3, 385, __pyx_L1_error) /* "src/fuse_api.pxi":384 * if res == -errno.EINTR: * continue * elif res < 0: # <<<<<<<<<<<<<< * raise OSError(-res, 'fuse_session_receive_buf failed with ' * + strerror(-res)) */ } /* "src/fuse_api.pxi":387 * raise OSError(-res, 'fuse_session_receive_buf failed with ' * + strerror(-res)) * elif res == 0: # <<<<<<<<<<<<<< * break * */ __pyx_t_1 = ((__pyx_v_res == 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":388 * + strerror(-res)) * elif res == 0: * break # <<<<<<<<<<<<<< * * fuse_session_process_buf(session, &buf, ch) */ goto __pyx_L4_break; /* "src/fuse_api.pxi":387 * raise OSError(-res, 'fuse_session_receive_buf failed with ' * + strerror(-res)) * elif res == 0: # <<<<<<<<<<<<<< * break * */ } /* "src/fuse_api.pxi":390 * break * * fuse_session_process_buf(session, &buf, ch) # <<<<<<<<<<<<<< * * ctypedef struct worker_data_t: */ fuse_session_process_buf(__pyx_v_6llfuse_session, (&__pyx_v_buf), __pyx_v_ch); __pyx_L3_continue:; } __pyx_L4_break:; /* "src/fuse_api.pxi":366 * stdlib.free(mem) * * cdef session_loop(void* mem, size_t size): # <<<<<<<<<<<<<< * '''Process requests''' * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("llfuse.session_loop", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":400 * size_t bufsize * * cdef void* worker_start(void* data) with gil: # <<<<<<<<<<<<<< * cdef worker_data_t *wd * cdef int res */ static void *__pyx_f_6llfuse_worker_start(void *__pyx_v_data) { __pyx_t_6llfuse_worker_data_t *__pyx_v_wd; int __pyx_v_res; PyObject *__pyx_v_t = NULL; void *__pyx_r; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; PyObject *__pyx_t_10 = NULL; int __pyx_t_11; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; int __pyx_t_14; int __pyx_t_15; char const *__pyx_t_16; PyObject *__pyx_t_17 = NULL; PyObject *__pyx_t_18 = NULL; PyObject *__pyx_t_19 = NULL; #ifdef WITH_THREAD PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure(); #endif __Pyx_RefNannySetupContext("worker_start", 0); /* "src/fuse_api.pxi":405 * global exc_info * * wd = data # <<<<<<<<<<<<<< * * t = threading.current_thread() */ __pyx_v_wd = ((__pyx_t_6llfuse_worker_data_t *)__pyx_v_data); /* "src/fuse_api.pxi":407 * wd = data * * t = threading.current_thread() # <<<<<<<<<<<<<< * t.name = 'fuse-worker-%d' % (wd.thread_no+1,) * */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_threading); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_current_thread); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 407, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_2)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_2); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); } } if (__pyx_t_2) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 407, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 407, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_v_t = __pyx_t_1; __pyx_t_1 = 0; /* "src/fuse_api.pxi":408 * * t = threading.current_thread() * t.name = 'fuse-worker-%d' % (wd.thread_no+1,) # <<<<<<<<<<<<<< * * try: */ __pyx_t_1 = __Pyx_PyInt_From_long((__pyx_v_wd->thread_no + 1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 408, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 408, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_fuse_worker_d, __pyx_t_3); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 408, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (__Pyx_PyObject_SetAttrStr(__pyx_v_t, __pyx_n_s_name, __pyx_t_1) < 0) __PYX_ERR(3, 408, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":410 * t.name = 'fuse-worker-%d' % (wd.thread_no+1,) * * try: # <<<<<<<<<<<<<< * session_loop(wd.buf, wd.bufsize) * except: */ /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_4, &__pyx_t_5, &__pyx_t_6); __Pyx_XGOTREF(__pyx_t_4); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_6); /*try:*/ { /* "src/fuse_api.pxi":411 * * try: * session_loop(wd.buf, wd.bufsize) # <<<<<<<<<<<<<< * except: * fuse_session_exit(session) */ __pyx_t_1 = __pyx_f_6llfuse_session_loop(__pyx_v_wd->buf, __pyx_v_wd->bufsize); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 411, __pyx_L6_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":410 * t.name = 'fuse-worker-%d' % (wd.thread_no+1,) * * try: # <<<<<<<<<<<<<< * session_loop(wd.buf, wd.bufsize) * except: */ } __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; goto __pyx_L13_try_end; __pyx_L6_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":412 * try: * session_loop(wd.buf, wd.bufsize) * except: # <<<<<<<<<<<<<< * fuse_session_exit(session) * log.error('FUSE worker thread %d terminated with exception, ' */ /*except:*/ { __Pyx_AddTraceback("llfuse.worker_start", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_1, &__pyx_t_3, &__pyx_t_2) < 0) __PYX_ERR(3, 412, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_3); __Pyx_GOTREF(__pyx_t_2); /* "src/fuse_api.pxi":413 * session_loop(wd.buf, wd.bufsize) * except: * fuse_session_exit(session) # <<<<<<<<<<<<<< * log.error('FUSE worker thread %d terminated with exception, ' * 'aborting processing', wd.thread_id) */ fuse_session_exit(__pyx_v_6llfuse_session); /* "src/fuse_api.pxi":414 * except: * fuse_session_exit(session) * log.error('FUSE worker thread %d terminated with exception, ' # <<<<<<<<<<<<<< * 'aborting processing', wd.thread_id) * res = pthread_mutex_lock(&exc_info_mutex) */ __pyx_t_8 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_error); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; /* "src/fuse_api.pxi":415 * fuse_session_exit(session) * log.error('FUSE worker thread %d terminated with exception, ' * 'aborting processing', wd.thread_id) # <<<<<<<<<<<<<< * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: */ __pyx_t_8 = __Pyx_PyInt_From_pthread_t(__pyx_v_wd->thread_id); if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 415, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_10 = NULL; __pyx_t_11 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_9))) { __pyx_t_10 = PyMethod_GET_SELF(__pyx_t_9); if (likely(__pyx_t_10)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); __Pyx_INCREF(__pyx_t_10); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_9, function); __pyx_t_11 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_10, __pyx_kp_u_FUSE_worker_thread_d_terminated, __pyx_t_8}; __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_10, __pyx_kp_u_FUSE_worker_thread_d_terminated, __pyx_t_8}; __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } else #endif { __pyx_t_12 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_12); if (__pyx_t_10) { __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_12, 0, __pyx_t_10); __pyx_t_10 = NULL; } __Pyx_INCREF(__pyx_kp_u_FUSE_worker_thread_d_terminated); __Pyx_GIVEREF(__pyx_kp_u_FUSE_worker_thread_d_terminated); PyTuple_SET_ITEM(__pyx_t_12, 0+__pyx_t_11, __pyx_kp_u_FUSE_worker_thread_d_terminated); __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_12, 1+__pyx_t_11, __pyx_t_8); __pyx_t_8 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_12, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 414, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/fuse_api.pxi":416 * log.error('FUSE worker thread %d terminated with exception, ' * 'aborting processing', wd.thread_id) * res = pthread_mutex_lock(&exc_info_mutex) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_mutex_lock failed with %s', */ __pyx_v_res = pthread_mutex_lock((&__pyx_v_6llfuse_exc_info_mutex)); /* "src/fuse_api.pxi":417 * 'aborting processing', wd.thread_id) * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_lock failed with %s', * strerror(res)) */ __pyx_t_13 = ((__pyx_v_res != 0) != 0); if (__pyx_t_13) { /* "src/fuse_api.pxi":418 * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: * log.error('pthread_mutex_lock failed with %s', # <<<<<<<<<<<<<< * strerror(res)) * if not exc_info: */ __pyx_t_9 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_error); if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; /* "src/fuse_api.pxi":419 * if res != 0: * log.error('pthread_mutex_lock failed with %s', * strerror(res)) # <<<<<<<<<<<<<< * if not exc_info: * exc_info = sys.exc_info() */ __pyx_t_9 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 419, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_8 = NULL; __pyx_t_11 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_12))) { __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_12); if (likely(__pyx_t_8)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_12); __Pyx_INCREF(__pyx_t_8); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_12, function); __pyx_t_11 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_12)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_pthread_mutex_lock_failed_with_s, __pyx_t_9}; __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_12, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_12)) { PyObject *__pyx_temp[3] = {__pyx_t_8, __pyx_kp_u_pthread_mutex_lock_failed_with_s, __pyx_t_9}; __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_12, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif { __pyx_t_10 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_10); if (__pyx_t_8) { __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_8); __pyx_t_8 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_mutex_lock_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_mutex_lock_failed_with_s); PyTuple_SET_ITEM(__pyx_t_10, 0+__pyx_t_11, __pyx_kp_u_pthread_mutex_lock_failed_with_s); __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_10, 1+__pyx_t_11, __pyx_t_9); __pyx_t_9 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_12, __pyx_t_10, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 418, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/fuse_api.pxi":417 * 'aborting processing', wd.thread_id) * res = pthread_mutex_lock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_lock failed with %s', * strerror(res)) */ } /* "src/fuse_api.pxi":420 * log.error('pthread_mutex_lock failed with %s', * strerror(res)) * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * else: */ __pyx_t_13 = __Pyx_PyObject_IsTrue(__pyx_v_6llfuse_exc_info); if (unlikely(__pyx_t_13 < 0)) __PYX_ERR(3, 420, __pyx_L8_except_error) __pyx_t_14 = ((!__pyx_t_13) != 0); if (__pyx_t_14) { /* "src/fuse_api.pxi":421 * strerror(res)) * if not exc_info: * exc_info = sys.exc_info() # <<<<<<<<<<<<<< * else: * log.exception('Only one exception can be re-raised, the following ' */ __pyx_t_12 = __Pyx_GetModuleGlobalName(__pyx_n_s_sys); if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 421, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_12, __pyx_n_s_exc_info); if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 421, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __pyx_t_12 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_10))) { __pyx_t_12 = PyMethod_GET_SELF(__pyx_t_10); if (likely(__pyx_t_12)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_10); __Pyx_INCREF(__pyx_t_12); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_10, function); } } if (__pyx_t_12) { __pyx_t_7 = __Pyx_PyObject_CallOneArg(__pyx_t_10, __pyx_t_12); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 421, __pyx_L8_except_error) __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; } else { __pyx_t_7 = __Pyx_PyObject_CallNoArg(__pyx_t_10); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 421, __pyx_L8_except_error) } __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/fuse_api.pxi":420 * log.error('pthread_mutex_lock failed with %s', * strerror(res)) * if not exc_info: # <<<<<<<<<<<<<< * exc_info = sys.exc_info() * else: */ goto __pyx_L17; } /* "src/fuse_api.pxi":423 * exc_info = sys.exc_info() * else: * log.exception('Only one exception can be re-raised, the following ' # <<<<<<<<<<<<<< * 'exception will be lost:') * pthread_mutex_unlock(&exc_info_mutex) */ /*else*/ { __pyx_t_7 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 423, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_exception); if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 423, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_10); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_10, __pyx_tuple__78, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 423, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } __pyx_L17:; /* "src/fuse_api.pxi":425 * log.exception('Only one exception can be re-raised, the following ' * 'exception will be lost:') * pthread_mutex_unlock(&exc_info_mutex) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_mutex_ulock failed with %s', */ pthread_mutex_unlock((&__pyx_v_6llfuse_exc_info_mutex)); /* "src/fuse_api.pxi":426 * 'exception will be lost:') * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) */ __pyx_t_14 = ((__pyx_v_res != 0) != 0); if (__pyx_t_14) { /* "src/fuse_api.pxi":427 * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: * log.error('pthread_mutex_ulock failed with %s', # <<<<<<<<<<<<<< * strerror(res)) * */ __pyx_t_10 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_t_10, __pyx_n_s_error); if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_12); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; /* "src/fuse_api.pxi":428 * if res != 0: * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) # <<<<<<<<<<<<<< * * finally: */ __pyx_t_10 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 428, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_10); __pyx_t_9 = NULL; __pyx_t_11 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_12))) { __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_12); if (likely(__pyx_t_9)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_12); __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_12, function); __pyx_t_11 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_12)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_pthread_mutex_ulock_failed_with, __pyx_t_10}; __pyx_t_7 = __Pyx_PyFunction_FastCall(__pyx_t_12, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_12)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_pthread_mutex_ulock_failed_with, __pyx_t_10}; __pyx_t_7 = __Pyx_PyCFunction_FastCall(__pyx_t_12, __pyx_temp+1-__pyx_t_11, 2+__pyx_t_11); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0; } else #endif { __pyx_t_8 = PyTuple_New(2+__pyx_t_11); if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_8); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_9); __pyx_t_9 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_mutex_ulock_failed_with); __Pyx_GIVEREF(__pyx_kp_u_pthread_mutex_ulock_failed_with); PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_11, __pyx_kp_u_pthread_mutex_ulock_failed_with); __Pyx_GIVEREF(__pyx_t_10); PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_11, __pyx_t_10); __pyx_t_10 = 0; __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_12, __pyx_t_8, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 427, __pyx_L8_except_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; /* "src/fuse_api.pxi":426 * 'exception will be lost:') * pthread_mutex_unlock(&exc_info_mutex) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_mutex_ulock failed with %s', * strerror(res)) */ } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; goto __pyx_L7_exception_handled; } __pyx_L8_except_error:; /* "src/fuse_api.pxi":410 * t.name = 'fuse-worker-%d' % (wd.thread_no+1,) * * try: # <<<<<<<<<<<<<< * session_loop(wd.buf, wd.bufsize) * except: */ __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_6); __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6); goto __pyx_L4_error; __pyx_L7_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_4); __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_6); __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_5, __pyx_t_6); __pyx_L13_try_end:; } } /* "src/fuse_api.pxi":431 * * finally: * sem_post(wd.sem) # <<<<<<<<<<<<<< * * cdef session_loop_mt(workers): */ /*finally:*/ { /*normal exit:*/{ sem_post(__pyx_v_wd->sem); goto __pyx_L5; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L4_error:; __pyx_t_6 = 0; __pyx_t_5 = 0; __pyx_t_4 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; __pyx_t_19 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_XDECREF(__pyx_t_10); __pyx_t_10 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_XDECREF(__pyx_t_12); __pyx_t_12 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_17, &__pyx_t_18, &__pyx_t_19); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_6, &__pyx_t_5, &__pyx_t_4) < 0)) __Pyx_ErrFetch(&__pyx_t_6, &__pyx_t_5, &__pyx_t_4); __Pyx_XGOTREF(__pyx_t_6); __Pyx_XGOTREF(__pyx_t_5); __Pyx_XGOTREF(__pyx_t_4); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_18); __Pyx_XGOTREF(__pyx_t_19); __pyx_t_11 = __pyx_lineno; __pyx_t_15 = __pyx_clineno; __pyx_t_16 = __pyx_filename; { sem_post(__pyx_v_wd->sem); } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_XGIVEREF(__pyx_t_19); __Pyx_ExceptionReset(__pyx_t_17, __pyx_t_18, __pyx_t_19); } __Pyx_XGIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_5); __Pyx_XGIVEREF(__pyx_t_4); __Pyx_ErrRestore(__pyx_t_6, __pyx_t_5, __pyx_t_4); __pyx_t_6 = 0; __pyx_t_5 = 0; __pyx_t_4 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; __pyx_t_19 = 0; __pyx_lineno = __pyx_t_11; __pyx_clineno = __pyx_t_15; __pyx_filename = __pyx_t_16; goto __pyx_L1_error; } __pyx_L5:; } /* "src/fuse_api.pxi":400 * size_t bufsize * * cdef void* worker_start(void* data) with gil: # <<<<<<<<<<<<<< * cdef worker_data_t *wd * cdef int res */ /* function exit code */ __pyx_r = 0; goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __Pyx_XDECREF(__pyx_t_10); __Pyx_XDECREF(__pyx_t_12); __Pyx_WriteUnraisable("llfuse.worker_start", __pyx_clineno, __pyx_lineno, __pyx_filename, 0, 0); __pyx_r = 0; __pyx_L0:; __Pyx_XDECREF(__pyx_v_t); __Pyx_RefNannyFinishContext(); #ifdef WITH_THREAD PyGILState_Release(__pyx_gilstate_save); #endif return __pyx_r; } /* "src/fuse_api.pxi":433 * sem_post(wd.sem) * * cdef session_loop_mt(workers): # <<<<<<<<<<<<<< * cdef worker_data_t *wd * cdef sigset_t newset, oldset */ static PyObject *__pyx_f_6llfuse_session_loop_mt(PyObject *__pyx_v_workers) { __pyx_t_6llfuse_worker_data_t *__pyx_v_wd; sigset_t __pyx_v_newset; sigset_t __pyx_v_oldset; int __pyx_v_res; int __pyx_v_i; size_t __pyx_v_bufsize; sem_t __pyx_v_sem; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; size_t __pyx_t_5; void *__pyx_t_6; long __pyx_t_7; int __pyx_t_8; PyObject *__pyx_t_9 = NULL; int __pyx_t_10; PyObject *__pyx_t_11 = NULL; char const *__pyx_t_12; PyObject *__pyx_t_13 = NULL; PyObject *__pyx_t_14 = NULL; PyObject *__pyx_t_15 = NULL; PyObject *__pyx_t_16 = NULL; PyObject *__pyx_t_17 = NULL; PyObject *__pyx_t_18 = NULL; int __pyx_t_19; int __pyx_t_20; __Pyx_RefNannySetupContext("session_loop_mt", 0); /* "src/fuse_api.pxi":440 * cdef sem_t sem * * if sem_init(&sem, 0, 0) != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'sem_init failed with ' * + strerror(errno.errno)) */ __pyx_t_1 = ((sem_init((&__pyx_v_sem), 0, 0) != 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":441 * * if sem_init(&sem, 0, 0) != 0: * raise OSError(errno.errno, 'sem_init failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * */ __pyx_t_2 = __Pyx_PyInt_From_int(errno); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 441, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); /* "src/fuse_api.pxi":442 * if sem_init(&sem, 0, 0) != 0: * raise OSError(errno.errno, 'sem_init failed with ' * + strerror(errno.errno)) # <<<<<<<<<<<<<< * * sigemptyset(&newset); */ __pyx_t_3 = __pyx_f_6llfuse_strerror(errno); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = PyNumber_Add(__pyx_kp_u_sem_init_failed_with, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 442, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/fuse_api.pxi":441 * * if sem_init(&sem, 0, 0) != 0: * raise OSError(errno.errno, 'sem_init failed with ' # <<<<<<<<<<<<<< * + strerror(errno.errno)) * */ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 441, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4); __pyx_t_2 = 0; __pyx_t_4 = 0; __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 441, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_4, 0, 0, 0); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __PYX_ERR(3, 441, __pyx_L1_error) /* "src/fuse_api.pxi":440 * cdef sem_t sem * * if sem_init(&sem, 0, 0) != 0: # <<<<<<<<<<<<<< * raise OSError(errno.errno, 'sem_init failed with ' * + strerror(errno.errno)) */ } /* "src/fuse_api.pxi":444 * + strerror(errno.errno)) * * sigemptyset(&newset); # <<<<<<<<<<<<<< * sigaddset(&newset, signal.SIGTERM); * sigaddset(&newset, signal.SIGINT); */ sigemptyset((&__pyx_v_newset)); /* "src/fuse_api.pxi":445 * * sigemptyset(&newset); * sigaddset(&newset, signal.SIGTERM); # <<<<<<<<<<<<<< * sigaddset(&newset, signal.SIGINT); * sigaddset(&newset, signal.SIGHUP); */ sigaddset((&__pyx_v_newset), SIGTERM); /* "src/fuse_api.pxi":446 * sigemptyset(&newset); * sigaddset(&newset, signal.SIGTERM); * sigaddset(&newset, signal.SIGINT); # <<<<<<<<<<<<<< * sigaddset(&newset, signal.SIGHUP); * sigaddset(&newset, signal.SIGQUIT); */ sigaddset((&__pyx_v_newset), SIGINT); /* "src/fuse_api.pxi":447 * sigaddset(&newset, signal.SIGTERM); * sigaddset(&newset, signal.SIGINT); * sigaddset(&newset, signal.SIGHUP); # <<<<<<<<<<<<<< * sigaddset(&newset, signal.SIGQUIT); * */ sigaddset((&__pyx_v_newset), SIGHUP); /* "src/fuse_api.pxi":448 * sigaddset(&newset, signal.SIGINT); * sigaddset(&newset, signal.SIGHUP); * sigaddset(&newset, signal.SIGQUIT); # <<<<<<<<<<<<<< * * PyEval_InitThreads() */ sigaddset((&__pyx_v_newset), SIGQUIT); /* "src/fuse_api.pxi":450 * sigaddset(&newset, signal.SIGQUIT); * * PyEval_InitThreads() # <<<<<<<<<<<<<< * bufsize = fuse_chan_bufsize(channel) * wd = calloc_or_raise(workers, sizeof(worker_data_t)) */ PyEval_InitThreads(); /* "src/fuse_api.pxi":451 * * PyEval_InitThreads() * bufsize = fuse_chan_bufsize(channel) # <<<<<<<<<<<<<< * wd = calloc_or_raise(workers, sizeof(worker_data_t)) * try: */ __pyx_v_bufsize = fuse_chan_bufsize(__pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":452 * PyEval_InitThreads() * bufsize = fuse_chan_bufsize(channel) * wd = calloc_or_raise(workers, sizeof(worker_data_t)) # <<<<<<<<<<<<<< * try: * for i in range(workers): */ __pyx_t_5 = __Pyx_PyInt_As_size_t(__pyx_v_workers); if (unlikely((__pyx_t_5 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(3, 452, __pyx_L1_error) __pyx_t_6 = __pyx_f_6llfuse_calloc_or_raise(__pyx_t_5, (sizeof(__pyx_t_6llfuse_worker_data_t))); if (unlikely(__pyx_t_6 == NULL)) __PYX_ERR(3, 452, __pyx_L1_error) __pyx_v_wd = ((__pyx_t_6llfuse_worker_data_t *)__pyx_t_6); /* "src/fuse_api.pxi":453 * bufsize = fuse_chan_bufsize(channel) * wd = calloc_or_raise(workers, sizeof(worker_data_t)) * try: # <<<<<<<<<<<<<< * for i in range(workers): * wd[i].sem = &sem */ /*try:*/ { /* "src/fuse_api.pxi":454 * wd = calloc_or_raise(workers, sizeof(worker_data_t)) * try: * for i in range(workers): # <<<<<<<<<<<<<< * wd[i].sem = &sem * wd[i].thread_no = i */ __pyx_t_7 = __Pyx_PyInt_As_long(__pyx_v_workers); if (unlikely((__pyx_t_7 == (long)-1) && PyErr_Occurred())) __PYX_ERR(3, 454, __pyx_L5_error) for (__pyx_t_8 = 0; __pyx_t_8 < __pyx_t_7; __pyx_t_8+=1) { __pyx_v_i = __pyx_t_8; /* "src/fuse_api.pxi":455 * try: * for i in range(workers): * wd[i].sem = &sem # <<<<<<<<<<<<<< * wd[i].thread_no = i * wd[i].bufsize = bufsize */ (__pyx_v_wd[__pyx_v_i]).sem = (&__pyx_v_sem); /* "src/fuse_api.pxi":456 * for i in range(workers): * wd[i].sem = &sem * wd[i].thread_no = i # <<<<<<<<<<<<<< * wd[i].bufsize = bufsize * wd[i].buf = calloc_or_raise(1, bufsize) */ (__pyx_v_wd[__pyx_v_i]).thread_no = __pyx_v_i; /* "src/fuse_api.pxi":457 * wd[i].sem = &sem * wd[i].thread_no = i * wd[i].bufsize = bufsize # <<<<<<<<<<<<<< * wd[i].buf = calloc_or_raise(1, bufsize) * */ (__pyx_v_wd[__pyx_v_i]).bufsize = __pyx_v_bufsize; /* "src/fuse_api.pxi":458 * wd[i].thread_no = i * wd[i].bufsize = bufsize * wd[i].buf = calloc_or_raise(1, bufsize) # <<<<<<<<<<<<<< * * # Ensure that signals get delivered to main thread */ __pyx_t_6 = __pyx_f_6llfuse_calloc_or_raise(1, __pyx_v_bufsize); if (unlikely(__pyx_t_6 == NULL)) __PYX_ERR(3, 458, __pyx_L5_error) (__pyx_v_wd[__pyx_v_i]).buf = __pyx_t_6; /* "src/fuse_api.pxi":461 * * # Ensure that signals get delivered to main thread * pthread_sigmask(SIG_BLOCK, &newset, &oldset) # <<<<<<<<<<<<<< * res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) * pthread_sigmask(SIG_SETMASK, &oldset, NULL) */ pthread_sigmask(SIG_BLOCK, (&__pyx_v_newset), (&__pyx_v_oldset)); /* "src/fuse_api.pxi":462 * # Ensure that signals get delivered to main thread * pthread_sigmask(SIG_BLOCK, &newset, &oldset) * res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) # <<<<<<<<<<<<<< * pthread_sigmask(SIG_SETMASK, &oldset, NULL) * if res != 0: */ __pyx_v_res = pthread_create((&(__pyx_v_wd[__pyx_v_i]).thread_id), NULL, (&__pyx_f_6llfuse_worker_start), (__pyx_v_wd + __pyx_v_i)); /* "src/fuse_api.pxi":463 * pthread_sigmask(SIG_BLOCK, &newset, &oldset) * res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) * pthread_sigmask(SIG_SETMASK, &oldset, NULL) # <<<<<<<<<<<<<< * if res != 0: * raise OSError(res, 'pthread_create failed with ' */ pthread_sigmask(SIG_SETMASK, (&__pyx_v_oldset), NULL); /* "src/fuse_api.pxi":464 * res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) * pthread_sigmask(SIG_SETMASK, &oldset, NULL) * if res != 0: # <<<<<<<<<<<<<< * raise OSError(res, 'pthread_create failed with ' * + strerror(res)) */ __pyx_t_1 = ((__pyx_v_res != 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":465 * pthread_sigmask(SIG_SETMASK, &oldset, NULL) * if res != 0: * raise OSError(res, 'pthread_create failed with ' # <<<<<<<<<<<<<< * + strerror(res)) * wd[i].started = 1 */ __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_res); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 465, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_4); /* "src/fuse_api.pxi":466 * if res != 0: * raise OSError(res, 'pthread_create failed with ' * + strerror(res)) # <<<<<<<<<<<<<< * wd[i].started = 1 * */ __pyx_t_3 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 466, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_2 = PyNumber_Add(__pyx_kp_u_pthread_create_failed_with, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 466, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; /* "src/fuse_api.pxi":465 * pthread_sigmask(SIG_SETMASK, &oldset, NULL) * if res != 0: * raise OSError(res, 'pthread_create failed with ' # <<<<<<<<<<<<<< * + strerror(res)) * wd[i].started = 1 */ __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 465, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2); __pyx_t_4 = 0; __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 465, __pyx_L5_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_Raise(__pyx_t_2, 0, 0, 0); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __PYX_ERR(3, 465, __pyx_L5_error) /* "src/fuse_api.pxi":464 * res = pthread_create(&wd[i].thread_id, NULL, &worker_start, wd+i) * pthread_sigmask(SIG_SETMASK, &oldset, NULL) * if res != 0: # <<<<<<<<<<<<<< * raise OSError(res, 'pthread_create failed with ' * + strerror(res)) */ } /* "src/fuse_api.pxi":467 * raise OSError(res, 'pthread_create failed with ' * + strerror(res)) * wd[i].started = 1 # <<<<<<<<<<<<<< * * with nogil: */ (__pyx_v_wd[__pyx_v_i]).started = 1; } /* "src/fuse_api.pxi":469 * wd[i].started = 1 * * with nogil: # <<<<<<<<<<<<<< * while not fuse_session_exited(session): * sem_wait(&sem) # also interrupted by signals */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":470 * * with nogil: * while not fuse_session_exited(session): # <<<<<<<<<<<<<< * sem_wait(&sem) # also interrupted by signals * */ while (1) { __pyx_t_1 = ((!(fuse_session_exited(__pyx_v_6llfuse_session) != 0)) != 0); if (!__pyx_t_1) break; /* "src/fuse_api.pxi":471 * with nogil: * while not fuse_session_exited(session): * sem_wait(&sem) # also interrupted by signals # <<<<<<<<<<<<<< * * finally: */ sem_wait((&__pyx_v_sem)); } } /* "src/fuse_api.pxi":469 * wd[i].started = 1 * * with nogil: # <<<<<<<<<<<<<< * while not fuse_session_exited(session): * sem_wait(&sem) # also interrupted by signals */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L12; } __pyx_L12:; } } } /* "src/fuse_api.pxi":474 * * finally: * for i in range(workers): # <<<<<<<<<<<<<< * if wd[i].started: * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) */ /*finally:*/ { /*normal exit:*/{ __pyx_t_7 = __Pyx_PyInt_As_long(__pyx_v_workers); if (unlikely((__pyx_t_7 == (long)-1) && PyErr_Occurred())) __PYX_ERR(3, 474, __pyx_L1_error) for (__pyx_t_8 = 0; __pyx_t_8 < __pyx_t_7; __pyx_t_8+=1) { __pyx_v_i = __pyx_t_8; /* "src/fuse_api.pxi":475 * finally: * for i in range(workers): * if wd[i].started: # <<<<<<<<<<<<<< * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already */ __pyx_t_1 = ((__pyx_v_wd[__pyx_v_i]).started != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":476 * for i in range(workers): * if wd[i].started: * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) # <<<<<<<<<<<<<< * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: */ __pyx_v_res = pthread_kill((__pyx_v_wd[__pyx_v_i]).thread_id, SIGUSR1); /* "src/fuse_api.pxi":478 * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: # <<<<<<<<<<<<<< * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: */ switch (__pyx_v_res) { case 0: case ESRCH: __pyx_t_1 = 0; break; default: __pyx_t_1 = 1; break; } if (__pyx_t_1) { /* "src/fuse_api.pxi":479 * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) # <<<<<<<<<<<<<< * with nogil: * res = pthread_join(wd[i].thread_id, NULL) */ __pyx_t_3 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_error); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __pyx_t_3 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_9 = NULL; __pyx_t_10 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_9)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_9); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); __pyx_t_10 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_pthread_kill_failed_with_s, __pyx_t_3}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) { PyObject *__pyx_temp[3] = {__pyx_t_9, __pyx_kp_u_pthread_kill_failed_with_s, __pyx_t_3}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } else #endif { __pyx_t_11 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); if (__pyx_t_9) { __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_9); __pyx_t_9 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_kill_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_kill_failed_with_s); PyTuple_SET_ITEM(__pyx_t_11, 0+__pyx_t_10, __pyx_kp_u_pthread_kill_failed_with_s); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_11, 1+__pyx_t_10, __pyx_t_3); __pyx_t_3 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_11, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":478 * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: # <<<<<<<<<<<<<< * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: */ } /* "src/fuse_api.pxi":480 * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: # <<<<<<<<<<<<<< * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":481 * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: * res = pthread_join(wd[i].thread_id, NULL) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_join failed with: %s', strerror(res)) */ __pyx_v_res = pthread_join((__pyx_v_wd[__pyx_v_i]).thread_id, NULL); } /* "src/fuse_api.pxi":480 * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: # <<<<<<<<<<<<<< * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L23; } __pyx_L23:; } } /* "src/fuse_api.pxi":482 * with nogil: * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_join failed with: %s', strerror(res)) * */ __pyx_t_1 = ((__pyx_v_res != 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":483 * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: * log.error('pthread_join failed with: %s', strerror(res)) # <<<<<<<<<<<<<< * * if wd[i].buf != NULL: */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_error); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_11); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_3 = NULL; __pyx_t_10 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_11))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_11); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_11); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_11, function); __pyx_t_10 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_11)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_pthread_join_failed_with_s, __pyx_t_4}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_11, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_11)) { PyObject *__pyx_temp[3] = {__pyx_t_3, __pyx_kp_u_pthread_join_failed_with_s, __pyx_t_4}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_11, __pyx_temp+1-__pyx_t_10, 2+__pyx_t_10); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else #endif { __pyx_t_9 = PyTuple_New(2+__pyx_t_10); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); if (__pyx_t_3) { __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_3); __pyx_t_3 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_join_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_join_failed_with_s); PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_10, __pyx_kp_u_pthread_join_failed_with_s); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_10, __pyx_t_4); __pyx_t_4 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_11, __pyx_t_9, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":482 * with nogil: * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_join failed with: %s', strerror(res)) * */ } /* "src/fuse_api.pxi":475 * finally: * for i in range(workers): * if wd[i].started: # <<<<<<<<<<<<<< * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already */ } /* "src/fuse_api.pxi":485 * log.error('pthread_join failed with: %s', strerror(res)) * * if wd[i].buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(wd[i].buf) * */ __pyx_t_1 = (((__pyx_v_wd[__pyx_v_i]).buf != NULL) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":486 * * if wd[i].buf != NULL: * stdlib.free(wd[i].buf) # <<<<<<<<<<<<<< * * stdlib.free(wd) */ free((__pyx_v_wd[__pyx_v_i]).buf); /* "src/fuse_api.pxi":485 * log.error('pthread_join failed with: %s', strerror(res)) * * if wd[i].buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(wd[i].buf) * */ } } /* "src/fuse_api.pxi":488 * stdlib.free(wd[i].buf) * * stdlib.free(wd) # <<<<<<<<<<<<<< * * */ free(__pyx_v_wd); goto __pyx_L6; } /*exception exit:*/{ __Pyx_PyThreadState_declare __pyx_L5_error:; __pyx_t_13 = 0; __pyx_t_14 = 0; __pyx_t_15 = 0; __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_16, &__pyx_t_17, &__pyx_t_18); if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_13, &__pyx_t_14, &__pyx_t_15) < 0)) __Pyx_ErrFetch(&__pyx_t_13, &__pyx_t_14, &__pyx_t_15); __Pyx_XGOTREF(__pyx_t_13); __Pyx_XGOTREF(__pyx_t_14); __Pyx_XGOTREF(__pyx_t_15); __Pyx_XGOTREF(__pyx_t_16); __Pyx_XGOTREF(__pyx_t_17); __Pyx_XGOTREF(__pyx_t_18); __pyx_t_8 = __pyx_lineno; __pyx_t_10 = __pyx_clineno; __pyx_t_12 = __pyx_filename; { /* "src/fuse_api.pxi":474 * * finally: * for i in range(workers): # <<<<<<<<<<<<<< * if wd[i].started: * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) */ __pyx_t_7 = __Pyx_PyInt_As_long(__pyx_v_workers); if (unlikely((__pyx_t_7 == (long)-1) && PyErr_Occurred())) __PYX_ERR(3, 474, __pyx_L27_error) for (__pyx_t_19 = 0; __pyx_t_19 < __pyx_t_7; __pyx_t_19+=1) { __pyx_v_i = __pyx_t_19; /* "src/fuse_api.pxi":475 * finally: * for i in range(workers): * if wd[i].started: # <<<<<<<<<<<<<< * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already */ __pyx_t_1 = ((__pyx_v_wd[__pyx_v_i]).started != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":476 * for i in range(workers): * if wd[i].started: * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) # <<<<<<<<<<<<<< * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: */ __pyx_v_res = pthread_kill((__pyx_v_wd[__pyx_v_i]).thread_id, SIGUSR1); /* "src/fuse_api.pxi":478 * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: # <<<<<<<<<<<<<< * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: */ switch (__pyx_v_res) { case 0: case ESRCH: __pyx_t_1 = 0; break; default: __pyx_t_1 = 1; break; } if (__pyx_t_1) { /* "src/fuse_api.pxi":479 * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) # <<<<<<<<<<<<<< * with nogil: * res = pthread_join(wd[i].thread_id, NULL) */ __pyx_t_11 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_t_11, __pyx_n_s_error); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; __pyx_t_11 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_11)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_11); __pyx_t_4 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_9))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_9); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_9); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_9, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_kp_u_pthread_kill_failed_with_s, __pyx_t_11}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_9)) { PyObject *__pyx_temp[3] = {__pyx_t_4, __pyx_kp_u_pthread_kill_failed_with_s, __pyx_t_11}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_9, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0; } else #endif { __pyx_t_3 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_3); if (__pyx_t_4) { __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_kill_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_kill_failed_with_s); PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_20, __pyx_kp_u_pthread_kill_failed_with_s); __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_20, __pyx_t_11); __pyx_t_11 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_9, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 479, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; } __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":478 * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already * if res != 0 and res != errno.ESRCH: # <<<<<<<<<<<<<< * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: */ } /* "src/fuse_api.pxi":480 * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: # <<<<<<<<<<<<<< * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":481 * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: * res = pthread_join(wd[i].thread_id, NULL) # <<<<<<<<<<<<<< * if res != 0: * log.error('pthread_join failed with: %s', strerror(res)) */ __pyx_v_res = pthread_join((__pyx_v_wd[__pyx_v_i]).thread_id, NULL); } /* "src/fuse_api.pxi":480 * if res != 0 and res != errno.ESRCH: * log.error('pthread_kill failed with: %s', strerror(res)) * with nogil: # <<<<<<<<<<<<<< * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L36; } __pyx_L36:; } } /* "src/fuse_api.pxi":482 * with nogil: * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_join failed with: %s', strerror(res)) * */ __pyx_t_1 = ((__pyx_v_res != 0) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":483 * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: * log.error('pthread_join failed with: %s', strerror(res)) # <<<<<<<<<<<<<< * * if wd[i].buf != NULL: */ __pyx_t_9 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_9, __pyx_n_s_error); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_3); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __pyx_t_9 = __pyx_f_6llfuse_strerror(__pyx_v_res); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_9); __pyx_t_11 = NULL; __pyx_t_20 = 0; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) { __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_11)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_11); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); __pyx_t_20 = 1; } } #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_11, __pyx_kp_u_pthread_join_failed_with_s, __pyx_t_9}; __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[3] = {__pyx_t_11, __pyx_kp_u_pthread_join_failed_with_s, __pyx_t_9}; __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_20, 2+__pyx_t_20); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0; __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; } else #endif { __pyx_t_4 = PyTuple_New(2+__pyx_t_20); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_4); if (__pyx_t_11) { __Pyx_GIVEREF(__pyx_t_11); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_11); __pyx_t_11 = NULL; } __Pyx_INCREF(__pyx_kp_u_pthread_join_failed_with_s); __Pyx_GIVEREF(__pyx_kp_u_pthread_join_failed_with_s); PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_20, __pyx_kp_u_pthread_join_failed_with_s); __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_20, __pyx_t_9); __pyx_t_9 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 483, __pyx_L27_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":482 * with nogil: * res = pthread_join(wd[i].thread_id, NULL) * if res != 0: # <<<<<<<<<<<<<< * log.error('pthread_join failed with: %s', strerror(res)) * */ } /* "src/fuse_api.pxi":475 * finally: * for i in range(workers): * if wd[i].started: # <<<<<<<<<<<<<< * res = pthread_kill(wd[i].thread_id, signal.SIGUSR1) * # Thread may have terminated already */ } /* "src/fuse_api.pxi":485 * log.error('pthread_join failed with: %s', strerror(res)) * * if wd[i].buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(wd[i].buf) * */ __pyx_t_1 = (((__pyx_v_wd[__pyx_v_i]).buf != NULL) != 0); if (__pyx_t_1) { /* "src/fuse_api.pxi":486 * * if wd[i].buf != NULL: * stdlib.free(wd[i].buf) # <<<<<<<<<<<<<< * * stdlib.free(wd) */ free((__pyx_v_wd[__pyx_v_i]).buf); /* "src/fuse_api.pxi":485 * log.error('pthread_join failed with: %s', strerror(res)) * * if wd[i].buf != NULL: # <<<<<<<<<<<<<< * stdlib.free(wd[i].buf) * */ } } /* "src/fuse_api.pxi":488 * stdlib.free(wd[i].buf) * * stdlib.free(wd) # <<<<<<<<<<<<<< * * */ free(__pyx_v_wd); } __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); } __Pyx_XGIVEREF(__pyx_t_13); __Pyx_XGIVEREF(__pyx_t_14); __Pyx_XGIVEREF(__pyx_t_15); __Pyx_ErrRestore(__pyx_t_13, __pyx_t_14, __pyx_t_15); __pyx_t_13 = 0; __pyx_t_14 = 0; __pyx_t_15 = 0; __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; __pyx_lineno = __pyx_t_8; __pyx_clineno = __pyx_t_10; __pyx_filename = __pyx_t_12; goto __pyx_L1_error; __pyx_L27_error:; __Pyx_PyThreadState_assign if (PY_MAJOR_VERSION >= 3) { __Pyx_XGIVEREF(__pyx_t_16); __Pyx_XGIVEREF(__pyx_t_17); __Pyx_XGIVEREF(__pyx_t_18); __Pyx_ExceptionReset(__pyx_t_16, __pyx_t_17, __pyx_t_18); } __Pyx_XDECREF(__pyx_t_13); __pyx_t_13 = 0; __Pyx_XDECREF(__pyx_t_14); __pyx_t_14 = 0; __Pyx_XDECREF(__pyx_t_15); __pyx_t_15 = 0; __pyx_t_16 = 0; __pyx_t_17 = 0; __pyx_t_18 = 0; goto __pyx_L1_error; } __pyx_L6:; } /* "src/fuse_api.pxi":433 * sem_post(wd.sem) * * cdef session_loop_mt(workers): # <<<<<<<<<<<<<< * cdef worker_data_t *wd * cdef sigset_t newset, oldset */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_9); __Pyx_XDECREF(__pyx_t_11); __Pyx_AddTraceback("llfuse.session_loop_mt", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = 0; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":491 * * * def close(unmount=True): # <<<<<<<<<<<<<< * '''Clean up and ensure filesystem is unmounted * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_13close(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_12close[] = "close(unmount=True)\nClean up and ensure filesystem is unmounted\n\n If *unmount* is False, only clean up operations are peformed, but the file\n system is not explicitly unmounted.\n\n Normally, the filesystem is unmounted by the user calling umount(8) or\n fusermount(1), which then terminates the FUSE main loop. However, the loop\n may also terminate as a result of an exception or a signal. In this case the\n filesystem remains mounted, but any attempt to access it will block (while\n the filesystem process is still running) or (after the filesystem process\n has terminated) return an error. If *unmount* is True, this function will\n ensure that the filesystem is properly unmounted.\n\n Note: if the connection to the kernel is terminated via the\n ``/sys/fs/fuse/connections/`` interface, this function will *not* unmount\n the filesystem even if *unmount* is True.\n "; static PyMethodDef __pyx_mdef_6llfuse_13close = {"close", (PyCFunction)__pyx_pw_6llfuse_13close, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_12close}; static PyObject *__pyx_pw_6llfuse_13close(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_unmount = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("close (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_unmount,0}; PyObject* values[1] = {0}; values[0] = ((PyObject *)Py_True); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_unmount); if (value) { values[0] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "close") < 0)) __PYX_ERR(3, 491, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_unmount = values[0]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("close", 0, 0, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 491, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.close", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_12close(__pyx_self, __pyx_v_unmount); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_12close(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_unmount) { PyObject *__pyx_v_tmp = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; char *__pyx_t_4; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; __Pyx_RefNannySetupContext("close", 0); /* "src/fuse_api.pxi":515 * global exc_info * * log.debug('Calling fuse_session_remove_chan') # <<<<<<<<<<<<<< * fuse_session_remove_chan(channel) * log.debug('Calling fuse_session_destroy') */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 515, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 515, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__79, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 515, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":516 * * log.debug('Calling fuse_session_remove_chan') * fuse_session_remove_chan(channel) # <<<<<<<<<<<<<< * log.debug('Calling fuse_session_destroy') * fuse_session_destroy(session) */ fuse_session_remove_chan(__pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":517 * log.debug('Calling fuse_session_remove_chan') * fuse_session_remove_chan(channel) * log.debug('Calling fuse_session_destroy') # <<<<<<<<<<<<<< * fuse_session_destroy(session) * */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__80, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":518 * fuse_session_remove_chan(channel) * log.debug('Calling fuse_session_destroy') * fuse_session_destroy(session) # <<<<<<<<<<<<<< * * if unmount: */ fuse_session_destroy(__pyx_v_6llfuse_session); /* "src/fuse_api.pxi":520 * fuse_session_destroy(session) * * if unmount: # <<<<<<<<<<<<<< * log.debug('Calling fuse_unmount') * fuse_unmount(mountpoint_b, channel) */ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_unmount); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 520, __pyx_L1_error) if (__pyx_t_3) { /* "src/fuse_api.pxi":521 * * if unmount: * log.debug('Calling fuse_unmount') # <<<<<<<<<<<<<< * fuse_unmount(mountpoint_b, channel) * else: */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_log); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_debug); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple__81, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":522 * if unmount: * log.debug('Calling fuse_unmount') * fuse_unmount(mountpoint_b, channel) # <<<<<<<<<<<<<< * else: * fuse_chan_destroy(channel) */ __pyx_t_4 = __Pyx_PyObject_AsString(__pyx_v_6llfuse_mountpoint_b); if (unlikely((!__pyx_t_4) && PyErr_Occurred())) __PYX_ERR(3, 522, __pyx_L1_error) fuse_unmount(((char *)__pyx_t_4), __pyx_v_6llfuse_channel); /* "src/fuse_api.pxi":520 * fuse_session_destroy(session) * * if unmount: # <<<<<<<<<<<<<< * log.debug('Calling fuse_unmount') * fuse_unmount(mountpoint_b, channel) */ goto __pyx_L3; } /* "src/fuse_api.pxi":524 * fuse_unmount(mountpoint_b, channel) * else: * fuse_chan_destroy(channel) # <<<<<<<<<<<<<< * * mountpoint_b = None */ /*else*/ { fuse_chan_destroy(__pyx_v_6llfuse_channel); } __pyx_L3:; /* "src/fuse_api.pxi":526 * fuse_chan_destroy(channel) * * mountpoint_b = None # <<<<<<<<<<<<<< * session = NULL * channel = NULL */ __Pyx_INCREF(Py_None); __Pyx_XGOTREF(__pyx_v_6llfuse_mountpoint_b); __Pyx_DECREF_SET(__pyx_v_6llfuse_mountpoint_b, Py_None); __Pyx_GIVEREF(Py_None); /* "src/fuse_api.pxi":527 * * mountpoint_b = None * session = NULL # <<<<<<<<<<<<<< * channel = NULL * */ __pyx_v_6llfuse_session = NULL; /* "src/fuse_api.pxi":528 * mountpoint_b = None * session = NULL * channel = NULL # <<<<<<<<<<<<<< * * # destroy handler may have given us an exception */ __pyx_v_6llfuse_channel = NULL; /* "src/fuse_api.pxi":531 * * # destroy handler may have given us an exception * if exc_info: # <<<<<<<<<<<<<< * tmp = exc_info * exc_info = None */ __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_6llfuse_exc_info); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 531, __pyx_L1_error) if (__pyx_t_3) { /* "src/fuse_api.pxi":532 * # destroy handler may have given us an exception * if exc_info: * tmp = exc_info # <<<<<<<<<<<<<< * exc_info = None * */ __Pyx_INCREF(__pyx_v_6llfuse_exc_info); __pyx_v_tmp = __pyx_v_6llfuse_exc_info; /* "src/fuse_api.pxi":533 * if exc_info: * tmp = exc_info * exc_info = None # <<<<<<<<<<<<<< * * # The explicit version check works around a Cython bug with */ __Pyx_INCREF(Py_None); __Pyx_XGOTREF(__pyx_v_6llfuse_exc_info); __Pyx_DECREF_SET(__pyx_v_6llfuse_exc_info, Py_None); __Pyx_GIVEREF(Py_None); /* "src/fuse_api.pxi":538 * # the 3-parameter version of the raise statement, c.f. * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * raise tmp[0], tmp[1], tmp[2] * else: */ __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0); if (__pyx_t_3) { /* "src/fuse_api.pxi":539 * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: * raise tmp[0], tmp[1], tmp[2] # <<<<<<<<<<<<<< * else: * raise tmp[1].with_traceback(tmp[2]) */ __pyx_t_1 = __Pyx_GetItemInt(__pyx_v_tmp, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_GetItemInt(__pyx_v_tmp, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_5 = __Pyx_GetItemInt(__pyx_v_tmp, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 539, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_Raise(__pyx_t_1, __pyx_t_2, __pyx_t_5, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(3, 539, __pyx_L1_error) /* "src/fuse_api.pxi":538 * # the 3-parameter version of the raise statement, c.f. * # https://github.com/cython/cython/commit/a6195f1a44ab21f5aa4b2a1b1842dd93115a3f42 * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * raise tmp[0], tmp[1], tmp[2] * else: */ } /* "src/fuse_api.pxi":541 * raise tmp[0], tmp[1], tmp[2] * else: * raise tmp[1].with_traceback(tmp[2]) # <<<<<<<<<<<<<< * * def invalidate_inode(fuse_ino_t inode, attr_only=False): */ /*else*/ { __pyx_t_2 = __Pyx_GetItemInt(__pyx_v_tmp, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_with_traceback); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_GetItemInt(__pyx_v_tmp, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_6 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_1); if (likely(__pyx_t_6)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); __Pyx_INCREF(__pyx_t_6); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_1, function); } } if (!__pyx_t_6) { __pyx_t_5 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_GOTREF(__pyx_t_5); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_t_2}; __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) { PyObject *__pyx_temp[2] = {__pyx_t_6, __pyx_t_2}; __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } else #endif { __pyx_t_7 = PyTuple_New(1+1); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_6); __pyx_t_6 = NULL; __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_7, 0+1, __pyx_t_2); __pyx_t_2 = 0; __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 541, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0; } } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_Raise(__pyx_t_5, 0, 0, 0); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __PYX_ERR(3, 541, __pyx_L1_error) } /* "src/fuse_api.pxi":531 * * # destroy handler may have given us an exception * if exc_info: # <<<<<<<<<<<<<< * tmp = exc_info * exc_info = None */ } /* "src/fuse_api.pxi":491 * * * def close(unmount=True): # <<<<<<<<<<<<<< * '''Clean up and ensure filesystem is unmounted * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_5); __Pyx_XDECREF(__pyx_t_6); __Pyx_XDECREF(__pyx_t_7); __Pyx_AddTraceback("llfuse.close", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_tmp); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":543 * raise tmp[1].with_traceback(tmp[2]) * * def invalidate_inode(fuse_ino_t inode, attr_only=False): # <<<<<<<<<<<<<< * '''Invalidate cache for *inode* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_15invalidate_inode(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_14invalidate_inode[] = "invalidate_inode(fuse_ino_t inode, attr_only=False)\nInvalidate cache for *inode*\n\n Instructs the FUSE kernel module to forgot cached attributes and\n data (unless *attr_only* is True) for *inode*. This operation is\n carried out asynchronously, i.e. the method may return before the\n kernel has executed the request.\n "; static PyMethodDef __pyx_mdef_6llfuse_15invalidate_inode = {"invalidate_inode", (PyCFunction)__pyx_pw_6llfuse_15invalidate_inode, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_14invalidate_inode}; static PyObject *__pyx_pw_6llfuse_15invalidate_inode(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { fuse_ino_t __pyx_v_inode; PyObject *__pyx_v_attr_only = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("invalidate_inode (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_inode,&__pyx_n_s_attr_only,0}; PyObject* values[2] = {0,0}; values[1] = ((PyObject *)Py_False); if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (kw_args > 0) { PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_n_s_attr_only); if (value) { values[1] = value; kw_args--; } } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "invalidate_inode") < 0)) __PYX_ERR(3, 543, __pyx_L3_error) } } else { switch (PyTuple_GET_SIZE(__pyx_args)) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); break; default: goto __pyx_L5_argtuple_error; } } __pyx_v_inode = __Pyx_PyInt_As_fuse_ino_t(values[0]); if (unlikely((__pyx_v_inode == ((fuse_ino_t)-1)) && PyErr_Occurred())) __PYX_ERR(3, 543, __pyx_L3_error) __pyx_v_attr_only = values[1]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("invalidate_inode", 0, 1, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 543, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.invalidate_inode", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_14invalidate_inode(__pyx_self, __pyx_v_inode, __pyx_v_attr_only); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_14invalidate_inode(CYTHON_UNUSED PyObject *__pyx_self, fuse_ino_t __pyx_v_inode, PyObject *__pyx_v_attr_only) { struct __pyx_obj_6llfuse_NotifyRequest *__pyx_v_req = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; int __pyx_t_2; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; __Pyx_RefNannySetupContext("invalidate_inode", 0); /* "src/fuse_api.pxi":553 * * cdef NotifyRequest req * req = NotifyRequest.__new__(NotifyRequest) # <<<<<<<<<<<<<< * req.kind = NOTIFY_INVAL_INODE * req.ino = inode */ __pyx_t_1 = __pyx_tp_new_6llfuse_NotifyRequest(((PyTypeObject *)__pyx_ptype_6llfuse_NotifyRequest), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 553, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_6llfuse_NotifyRequest)))) __PYX_ERR(3, 553, __pyx_L1_error) __pyx_v_req = ((struct __pyx_obj_6llfuse_NotifyRequest *)__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":554 * cdef NotifyRequest req * req = NotifyRequest.__new__(NotifyRequest) * req.kind = NOTIFY_INVAL_INODE # <<<<<<<<<<<<<< * req.ino = inode * req.attr_only = bool(attr_only) */ __pyx_v_req->kind = NOTIFY_INVAL_INODE; /* "src/fuse_api.pxi":555 * req = NotifyRequest.__new__(NotifyRequest) * req.kind = NOTIFY_INVAL_INODE * req.ino = inode # <<<<<<<<<<<<<< * req.attr_only = bool(attr_only) * _notify_queue.put(req) */ __pyx_v_req->ino = __pyx_v_inode; /* "src/fuse_api.pxi":556 * req.kind = NOTIFY_INVAL_INODE * req.ino = inode * req.attr_only = bool(attr_only) # <<<<<<<<<<<<<< * _notify_queue.put(req) * */ __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_attr_only); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(3, 556, __pyx_L1_error) __pyx_v_req->attr_only = (!(!__pyx_t_2)); /* "src/fuse_api.pxi":557 * req.ino = inode * req.attr_only = bool(attr_only) * _notify_queue.put(req) # <<<<<<<<<<<<<< * * def invalidate_entry(fuse_ino_t inode_p, bytes name): */ __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse__notify_queue, __pyx_n_s_put); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_3, function); } } if (!__pyx_t_4) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_v_req)); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[2] = {__pyx_t_4, ((PyObject *)__pyx_v_req)}; __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) { PyObject *__pyx_temp[2] = {__pyx_t_4, ((PyObject *)__pyx_v_req)}; __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { __pyx_t_5 = PyTuple_New(1+1); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4); __pyx_t_4 = NULL; __Pyx_INCREF(((PyObject *)__pyx_v_req)); __Pyx_GIVEREF(((PyObject *)__pyx_v_req)); PyTuple_SET_ITEM(__pyx_t_5, 0+1, ((PyObject *)__pyx_v_req)); __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 557, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } } __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":543 * raise tmp[1].with_traceback(tmp[2]) * * def invalidate_inode(fuse_ino_t inode, attr_only=False): # <<<<<<<<<<<<<< * '''Invalidate cache for *inode* * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("llfuse.invalidate_inode", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_req); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":559 * _notify_queue.put(req) * * def invalidate_entry(fuse_ino_t inode_p, bytes name): # <<<<<<<<<<<<<< * '''Invalidate directory entry * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_17invalidate_entry(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_16invalidate_entry[] = "invalidate_entry(fuse_ino_t inode_p, bytes name)\nInvalidate directory entry\n\n Instructs the FUSE kernel module to forget about the directory\n entry *name* in the directory with inode *inode_p*. This operation\n is carried out asynchronously, i.e. the method may return before\n the kernel has executed the request.\n "; static PyMethodDef __pyx_mdef_6llfuse_17invalidate_entry = {"invalidate_entry", (PyCFunction)__pyx_pw_6llfuse_17invalidate_entry, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_16invalidate_entry}; static PyObject *__pyx_pw_6llfuse_17invalidate_entry(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { fuse_ino_t __pyx_v_inode_p; PyObject *__pyx_v_name = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("invalidate_entry (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_inode_p,&__pyx_n_s_name,0}; PyObject* values[2] = {0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode_p)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("invalidate_entry", 1, 2, 2, 1); __PYX_ERR(3, 559, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "invalidate_entry") < 0)) __PYX_ERR(3, 559, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 2) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); } __pyx_v_inode_p = __Pyx_PyInt_As_fuse_ino_t(values[0]); if (unlikely((__pyx_v_inode_p == ((fuse_ino_t)-1)) && PyErr_Occurred())) __PYX_ERR(3, 559, __pyx_L3_error) __pyx_v_name = ((PyObject*)values[1]); } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("invalidate_entry", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 559, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.invalidate_entry", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_name), (&PyBytes_Type), 1, "name", 1))) __PYX_ERR(3, 559, __pyx_L1_error) __pyx_r = __pyx_pf_6llfuse_16invalidate_entry(__pyx_self, __pyx_v_inode_p, __pyx_v_name); /* function exit code */ goto __pyx_L0; __pyx_L1_error:; __pyx_r = NULL; __pyx_L0:; __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_16invalidate_entry(CYTHON_UNUSED PyObject *__pyx_self, fuse_ino_t __pyx_v_inode_p, PyObject *__pyx_v_name) { struct __pyx_obj_6llfuse_NotifyRequest *__pyx_v_req = 0; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; __Pyx_RefNannySetupContext("invalidate_entry", 0); /* "src/fuse_api.pxi":569 * * cdef NotifyRequest req * req = NotifyRequest.__new__(NotifyRequest) # <<<<<<<<<<<<<< * req.kind = NOTIFY_INVAL_ENTRY * req.ino = inode_p */ __pyx_t_1 = __pyx_tp_new_6llfuse_NotifyRequest(((PyTypeObject *)__pyx_ptype_6llfuse_NotifyRequest), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 569, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (!(likely(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_6llfuse_NotifyRequest)))) __PYX_ERR(3, 569, __pyx_L1_error) __pyx_v_req = ((struct __pyx_obj_6llfuse_NotifyRequest *)__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":570 * cdef NotifyRequest req * req = NotifyRequest.__new__(NotifyRequest) * req.kind = NOTIFY_INVAL_ENTRY # <<<<<<<<<<<<<< * req.ino = inode_p * req.name = name */ __pyx_v_req->kind = NOTIFY_INVAL_ENTRY; /* "src/fuse_api.pxi":571 * req = NotifyRequest.__new__(NotifyRequest) * req.kind = NOTIFY_INVAL_ENTRY * req.ino = inode_p # <<<<<<<<<<<<<< * req.name = name * _notify_queue.put(req) */ __pyx_v_req->ino = __pyx_v_inode_p; /* "src/fuse_api.pxi":572 * req.kind = NOTIFY_INVAL_ENTRY * req.ino = inode_p * req.name = name # <<<<<<<<<<<<<< * _notify_queue.put(req) * */ __Pyx_INCREF(__pyx_v_name); __Pyx_GIVEREF(__pyx_v_name); __Pyx_GOTREF(__pyx_v_req->name); __Pyx_DECREF(__pyx_v_req->name); __pyx_v_req->name = __pyx_v_name; /* "src/fuse_api.pxi":573 * req.ino = inode_p * req.name = name * _notify_queue.put(req) # <<<<<<<<<<<<<< * * def get_ino_t_bits(): */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_6llfuse__notify_queue, __pyx_n_s_put); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_3 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) { __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_3)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_3); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (!__pyx_t_3) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_v_req)); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); } else { #if CYTHON_FAST_PYCALL if (PyFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_3, ((PyObject *)__pyx_v_req)}; __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif #if CYTHON_FAST_PYCCALL if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) { PyObject *__pyx_temp[2] = {__pyx_t_3, ((PyObject *)__pyx_v_req)}; __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-1, 1+1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_GOTREF(__pyx_t_1); } else #endif { __pyx_t_4 = PyTuple_New(1+1); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL; __Pyx_INCREF(((PyObject *)__pyx_v_req)); __Pyx_GIVEREF(((PyObject *)__pyx_v_req)); PyTuple_SET_ITEM(__pyx_t_4, 0+1, ((PyObject *)__pyx_v_req)); __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_4, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 573, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":559 * _notify_queue.put(req) * * def invalidate_entry(fuse_ino_t inode_p, bytes name): # <<<<<<<<<<<<<< * '''Invalidate directory entry * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_3); __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("llfuse.invalidate_entry", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF((PyObject *)__pyx_v_req); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":575 * _notify_queue.put(req) * * def get_ino_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bits available for inode numbers * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_19get_ino_t_bits(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_18get_ino_t_bits[] = "get_ino_t_bits()\nReturn number of bits available for inode numbers\n\n Attempts to use inode values that need more bytes will result in\n `OverflowError`.\n "; static PyMethodDef __pyx_mdef_6llfuse_19get_ino_t_bits = {"get_ino_t_bits", (PyCFunction)__pyx_pw_6llfuse_19get_ino_t_bits, METH_NOARGS, __pyx_doc_6llfuse_18get_ino_t_bits}; static PyObject *__pyx_pw_6llfuse_19get_ino_t_bits(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_ino_t_bits (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_18get_ino_t_bits(__pyx_self); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_18get_ino_t_bits(CYTHON_UNUSED PyObject *__pyx_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations size_t __pyx_t_1; size_t __pyx_t_2; size_t __pyx_t_3; PyObject *__pyx_t_4 = NULL; __Pyx_RefNannySetupContext("get_ino_t_bits", 0); /* "src/fuse_api.pxi":581 * `OverflowError`. * ''' * return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 # <<<<<<<<<<<<<< * * def get_off_t_bits(): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = (sizeof(fuse_ino_t)); __pyx_t_2 = (sizeof(ino_t)); if (((__pyx_t_1 < __pyx_t_2) != 0)) { __pyx_t_3 = __pyx_t_1; } else { __pyx_t_3 = __pyx_t_2; } __pyx_t_4 = __Pyx_PyInt_FromSize_t((__pyx_t_3 * 8)); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 581, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_r = __pyx_t_4; __pyx_t_4 = 0; goto __pyx_L0; /* "src/fuse_api.pxi":575 * _notify_queue.put(req) * * def get_ino_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bits available for inode numbers * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_4); __Pyx_AddTraceback("llfuse.get_ino_t_bits", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":583 * return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 * * def get_off_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bytes available for file offsets * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_21get_off_t_bits(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/ static char __pyx_doc_6llfuse_20get_off_t_bits[] = "get_off_t_bits()\nReturn number of bytes available for file offsets\n\n Attempts to use values whose representation needs more bytes will\n result in `OverflowError`.\n "; static PyMethodDef __pyx_mdef_6llfuse_21get_off_t_bits = {"get_off_t_bits", (PyCFunction)__pyx_pw_6llfuse_21get_off_t_bits, METH_NOARGS, __pyx_doc_6llfuse_20get_off_t_bits}; static PyObject *__pyx_pw_6llfuse_21get_off_t_bits(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_off_t_bits (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_20get_off_t_bits(__pyx_self); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_20get_off_t_bits(CYTHON_UNUSED PyObject *__pyx_self) { PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; __Pyx_RefNannySetupContext("get_off_t_bits", 0); /* "src/fuse_api.pxi":589 * result in `OverflowError`. * ''' * return sizeof(off_t) * 8 # <<<<<<<<<<<<<< * * def notify_store(inode, offset, data): */ __Pyx_XDECREF(__pyx_r); __pyx_t_1 = __Pyx_PyInt_FromSize_t(((sizeof(off_t)) * 8)); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 589, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_r = __pyx_t_1; __pyx_t_1 = 0; goto __pyx_L0; /* "src/fuse_api.pxi":583 * return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 * * def get_off_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bytes available for file offsets * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_AddTraceback("llfuse.get_off_t_bits", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":591 * return sizeof(off_t) * 8 * * def notify_store(inode, offset, data): # <<<<<<<<<<<<<< * '''Store data in kernel page cache * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_23notify_store(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_6llfuse_22notify_store[] = "notify_store(inode, offset, data)\nStore data in kernel page cache\n\n Sends *data* for the kernel to store it in the page cache for *inode* at\n *offset*. If this provides data beyond the current file size, the file is\n automatically extended.\n\n If this function raises an exception, the store may still have completed\n partially.\n "; static PyMethodDef __pyx_mdef_6llfuse_23notify_store = {"notify_store", (PyCFunction)__pyx_pw_6llfuse_23notify_store, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_22notify_store}; static PyObject *__pyx_pw_6llfuse_23notify_store(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_inode = 0; PyObject *__pyx_v_offset = 0; PyObject *__pyx_v_data = 0; PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("notify_store (wrapper)", 0); { static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_inode,&__pyx_n_s_offset,&__pyx_n_s_data,0}; PyObject* values[3] = {0,0,0}; if (unlikely(__pyx_kwds)) { Py_ssize_t kw_args; const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args); switch (pos_args) { case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2); case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1); case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0); case 0: break; default: goto __pyx_L5_argtuple_error; } kw_args = PyDict_Size(__pyx_kwds); switch (pos_args) { case 0: if (likely((values[0] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_inode)) != 0)) kw_args--; else goto __pyx_L5_argtuple_error; case 1: if (likely((values[1] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_offset)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("notify_store", 1, 3, 3, 1); __PYX_ERR(3, 591, __pyx_L3_error) } case 2: if (likely((values[2] = PyDict_GetItem(__pyx_kwds, __pyx_n_s_data)) != 0)) kw_args--; else { __Pyx_RaiseArgtupleInvalid("notify_store", 1, 3, 3, 2); __PYX_ERR(3, 591, __pyx_L3_error) } } if (unlikely(kw_args > 0)) { if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "notify_store") < 0)) __PYX_ERR(3, 591, __pyx_L3_error) } } else if (PyTuple_GET_SIZE(__pyx_args) != 3) { goto __pyx_L5_argtuple_error; } else { values[0] = PyTuple_GET_ITEM(__pyx_args, 0); values[1] = PyTuple_GET_ITEM(__pyx_args, 1); values[2] = PyTuple_GET_ITEM(__pyx_args, 2); } __pyx_v_inode = values[0]; __pyx_v_offset = values[1]; __pyx_v_data = values[2]; } goto __pyx_L4_argument_unpacking_done; __pyx_L5_argtuple_error:; __Pyx_RaiseArgtupleInvalid("notify_store", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(3, 591, __pyx_L3_error) __pyx_L3_error:; __Pyx_AddTraceback("llfuse.notify_store", __pyx_clineno, __pyx_lineno, __pyx_filename); __Pyx_RefNannyFinishContext(); return NULL; __pyx_L4_argument_unpacking_done:; __pyx_r = __pyx_pf_6llfuse_22notify_store(__pyx_self, __pyx_v_inode, __pyx_v_offset, __pyx_v_data); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_22notify_store(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_inode, PyObject *__pyx_v_offset, PyObject *__pyx_v_data) { int __pyx_v_ret; fuse_ino_t __pyx_v_ino; off_t __pyx_v_off; Py_buffer __pyx_v_pybuf; struct fuse_bufvec __pyx_v_bufvec; struct fuse_buf *__pyx_v_buf; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations int __pyx_t_1; struct fuse_buf *__pyx_t_2; void *__pyx_t_3; fuse_ino_t __pyx_t_4; off_t __pyx_t_5; int __pyx_t_6; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; PyObject *__pyx_t_9 = NULL; __Pyx_RefNannySetupContext("notify_store", 0); /* "src/fuse_api.pxi":609 * cdef fuse_buf *buf * * PyObject_GetBuffer(data, &pybuf, PyBUF_CONTIG_RO) # <<<<<<<<<<<<<< * bufvec.count = 1 * bufvec.idx = 0 */ __pyx_t_1 = PyObject_GetBuffer(__pyx_v_data, (&__pyx_v_pybuf), PyBUF_CONTIG_RO); if (unlikely(__pyx_t_1 == -1)) __PYX_ERR(3, 609, __pyx_L1_error) /* "src/fuse_api.pxi":610 * * PyObject_GetBuffer(data, &pybuf, PyBUF_CONTIG_RO) * bufvec.count = 1 # <<<<<<<<<<<<<< * bufvec.idx = 0 * bufvec.off = 0 */ __pyx_v_bufvec.count = 1; /* "src/fuse_api.pxi":611 * PyObject_GetBuffer(data, &pybuf, PyBUF_CONTIG_RO) * bufvec.count = 1 * bufvec.idx = 0 # <<<<<<<<<<<<<< * bufvec.off = 0 * */ __pyx_v_bufvec.idx = 0; /* "src/fuse_api.pxi":612 * bufvec.count = 1 * bufvec.idx = 0 * bufvec.off = 0 # <<<<<<<<<<<<<< * * buf = bufvec.buf */ __pyx_v_bufvec.off = 0; /* "src/fuse_api.pxi":614 * bufvec.off = 0 * * buf = bufvec.buf # <<<<<<<<<<<<<< * buf[0].flags = 0 * buf[0].mem = pybuf.buf */ __pyx_t_2 = __pyx_v_bufvec.buf; __pyx_v_buf = __pyx_t_2; /* "src/fuse_api.pxi":615 * * buf = bufvec.buf * buf[0].flags = 0 # <<<<<<<<<<<<<< * buf[0].mem = pybuf.buf * buf[0].size = pybuf.len # guaranteed positive */ (__pyx_v_buf[0]).flags = 0; /* "src/fuse_api.pxi":616 * buf = bufvec.buf * buf[0].flags = 0 * buf[0].mem = pybuf.buf # <<<<<<<<<<<<<< * buf[0].size = pybuf.len # guaranteed positive * */ __pyx_t_3 = __pyx_v_pybuf.buf; (__pyx_v_buf[0]).mem = __pyx_t_3; /* "src/fuse_api.pxi":617 * buf[0].flags = 0 * buf[0].mem = pybuf.buf * buf[0].size = pybuf.len # guaranteed positive # <<<<<<<<<<<<<< * * ino = inode */ (__pyx_v_buf[0]).size = ((size_t)__pyx_v_pybuf.len); /* "src/fuse_api.pxi":619 * buf[0].size = pybuf.len # guaranteed positive * * ino = inode # <<<<<<<<<<<<<< * off = offset * with nogil: */ __pyx_t_4 = __Pyx_PyInt_As_fuse_ino_t(__pyx_v_inode); if (unlikely((__pyx_t_4 == ((fuse_ino_t)-1)) && PyErr_Occurred())) __PYX_ERR(3, 619, __pyx_L1_error) __pyx_v_ino = __pyx_t_4; /* "src/fuse_api.pxi":620 * * ino = inode * off = offset # <<<<<<<<<<<<<< * with nogil: * ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) */ __pyx_t_5 = __Pyx_PyInt_As_off_t(__pyx_v_offset); if (unlikely((__pyx_t_5 == ((off_t)-1)) && PyErr_Occurred())) __PYX_ERR(3, 620, __pyx_L1_error) __pyx_v_off = __pyx_t_5; /* "src/fuse_api.pxi":621 * ino = inode * off = offset * with nogil: # <<<<<<<<<<<<<< * ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) * */ { #ifdef WITH_THREAD PyThreadState *_save; Py_UNBLOCK_THREADS #endif /*try:*/ { /* "src/fuse_api.pxi":622 * off = offset * with nogil: * ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) # <<<<<<<<<<<<<< * * PyBuffer_Release(&pybuf) */ __pyx_v_ret = fuse_lowlevel_notify_store(__pyx_v_6llfuse_channel, __pyx_v_ino, __pyx_v_off, (&__pyx_v_bufvec), 0); } /* "src/fuse_api.pxi":621 * ino = inode * off = offset * with nogil: # <<<<<<<<<<<<<< * ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) * */ /*finally:*/ { /*normal exit:*/{ #ifdef WITH_THREAD Py_BLOCK_THREADS #endif goto __pyx_L5; } __pyx_L5:; } } /* "src/fuse_api.pxi":624 * ret = fuse_lowlevel_notify_store(channel, ino, off, &bufvec, 0) * * PyBuffer_Release(&pybuf) # <<<<<<<<<<<<<< * if ret != 0: * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) */ PyBuffer_Release((&__pyx_v_pybuf)); /* "src/fuse_api.pxi":625 * * PyBuffer_Release(&pybuf) * if ret != 0: # <<<<<<<<<<<<<< * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * */ __pyx_t_6 = ((__pyx_v_ret != 0) != 0); if (__pyx_t_6) { /* "src/fuse_api.pxi":626 * PyBuffer_Release(&pybuf) * if ret != 0: * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) # <<<<<<<<<<<<<< * * def get_sup_groups(pid): */ __pyx_t_7 = __Pyx_PyInt_From_int((-__pyx_v_ret)); if (unlikely(!__pyx_t_7)) __PYX_ERR(3, 626, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_7); __pyx_t_8 = __pyx_f_6llfuse_strerror((-__pyx_v_ret)); if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 626, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __pyx_t_9 = PyNumber_Add(__pyx_kp_u_fuse_lowlevel_notify_store_retur, __pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 626, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 626, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_9); __pyx_t_7 = 0; __pyx_t_9 = 0; __pyx_t_9 = __Pyx_PyObject_Call(__pyx_builtin_OSError, __pyx_t_8, NULL); if (unlikely(!__pyx_t_9)) __PYX_ERR(3, 626, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_9); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; __Pyx_Raise(__pyx_t_9, 0, 0, 0); __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0; __PYX_ERR(3, 626, __pyx_L1_error) /* "src/fuse_api.pxi":625 * * PyBuffer_Release(&pybuf) * if ret != 0: # <<<<<<<<<<<<<< * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * */ } /* "src/fuse_api.pxi":591 * return sizeof(off_t) * 8 * * def notify_store(inode, offset, data): # <<<<<<<<<<<<<< * '''Store data in kernel page cache * */ /* function exit code */ __pyx_r = Py_None; __Pyx_INCREF(Py_None); goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_7); __Pyx_XDECREF(__pyx_t_8); __Pyx_XDECREF(__pyx_t_9); __Pyx_AddTraceback("llfuse.notify_store", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } /* "src/fuse_api.pxi":628 * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * * def get_sup_groups(pid): # <<<<<<<<<<<<<< * '''Return supplementary group ids of *pid* * */ /* Python wrapper */ static PyObject *__pyx_pw_6llfuse_25get_sup_groups(PyObject *__pyx_self, PyObject *__pyx_v_pid); /*proto*/ static char __pyx_doc_6llfuse_24get_sup_groups[] = "get_sup_groups(pid)\nReturn supplementary group ids of *pid*\n\n This function is relatively expensive because it has to read the group ids\n from ``/proc/[pid]/status``. For the same reason, it will also not work on\n systems that do not provide a ``/proc`` file system.\n\n Returns a set.\n "; static PyMethodDef __pyx_mdef_6llfuse_25get_sup_groups = {"get_sup_groups", (PyCFunction)__pyx_pw_6llfuse_25get_sup_groups, METH_O, __pyx_doc_6llfuse_24get_sup_groups}; static PyObject *__pyx_pw_6llfuse_25get_sup_groups(PyObject *__pyx_self, PyObject *__pyx_v_pid) { PyObject *__pyx_r = 0; __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("get_sup_groups (wrapper)", 0); __pyx_r = __pyx_pf_6llfuse_24get_sup_groups(__pyx_self, ((PyObject *)__pyx_v_pid)); /* function exit code */ __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_pf_6llfuse_24get_sup_groups(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_pid) { PyObject *__pyx_v_fh = NULL; PyObject *__pyx_v_line = NULL; PyObject *__pyx_v_gids = NULL; PyObject *__pyx_v_x = NULL; PyObject *__pyx_r = NULL; __Pyx_RefNannyDeclarations PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; PyObject *__pyx_t_3 = NULL; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; PyObject *__pyx_t_6 = NULL; PyObject *__pyx_t_7 = NULL; PyObject *__pyx_t_8 = NULL; Py_ssize_t __pyx_t_9; PyObject *(*__pyx_t_10)(PyObject *); int __pyx_t_11; PyObject *__pyx_t_12 = NULL; int __pyx_t_13; int __pyx_t_14; __Pyx_RefNannySetupContext("get_sup_groups", 0); /* "src/fuse_api.pxi":638 * ''' * * with open('/proc/%d/status' % pid, 'r') as fh: # <<<<<<<<<<<<<< * for line in fh: * if line.startswith('Groups:'): */ /*with:*/ { __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_proc_d_status, __pyx_v_pid); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __Pyx_INCREF(__pyx_n_u_r); __Pyx_GIVEREF(__pyx_n_u_r); PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_n_u_r); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_open, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_3 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_exit); if (unlikely(!__pyx_t_3)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_3); __pyx_t_4 = __Pyx_PyObject_LookupSpecial(__pyx_t_1, __pyx_n_s_enter); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 638, __pyx_L3_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_5 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) { __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_5)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_5); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_5) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 638, __pyx_L3_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; } else { __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 638, __pyx_L3_error) } __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = __pyx_t_2; __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /*try:*/ { { __Pyx_PyThreadState_declare __Pyx_PyThreadState_assign __Pyx_ExceptionSave(&__pyx_t_6, &__pyx_t_7, &__pyx_t_8); __Pyx_XGOTREF(__pyx_t_6); __Pyx_XGOTREF(__pyx_t_7); __Pyx_XGOTREF(__pyx_t_8); /*try:*/ { __pyx_v_fh = __pyx_t_4; __pyx_t_4 = 0; /* "src/fuse_api.pxi":639 * * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: # <<<<<<<<<<<<<< * if line.startswith('Groups:'): * break */ if (likely(PyList_CheckExact(__pyx_v_fh)) || PyTuple_CheckExact(__pyx_v_fh)) { __pyx_t_4 = __pyx_v_fh; __Pyx_INCREF(__pyx_t_4); __pyx_t_9 = 0; __pyx_t_10 = NULL; } else { __pyx_t_9 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_v_fh); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 639, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_10 = Py_TYPE(__pyx_t_4)->tp_iternext; if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 639, __pyx_L7_error) } for (;;) { if (likely(!__pyx_t_10)) { if (likely(PyList_CheckExact(__pyx_t_4))) { if (__pyx_t_9 >= PyList_GET_SIZE(__pyx_t_4)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_9); __Pyx_INCREF(__pyx_t_1); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(3, 639, __pyx_L7_error) #else __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 639, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_9 >= PyTuple_GET_SIZE(__pyx_t_4)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_9); __Pyx_INCREF(__pyx_t_1); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(3, 639, __pyx_L7_error) #else __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 639, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); #endif } } else { __pyx_t_1 = __pyx_t_10(__pyx_t_4); if (unlikely(!__pyx_t_1)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(3, 639, __pyx_L7_error) } break; } __Pyx_GOTREF(__pyx_t_1); } __Pyx_XDECREF_SET(__pyx_v_line, __pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":640 * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: * if line.startswith('Groups:'): # <<<<<<<<<<<<<< * break * else: */ __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_line, __pyx_n_s_startswith); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 640, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__82, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 640, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_11 < 0)) __PYX_ERR(3, 640, __pyx_L7_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_11) { /* "src/fuse_api.pxi":641 * for line in fh: * if line.startswith('Groups:'): * break # <<<<<<<<<<<<<< * else: * raise RuntimeError("Unable to parse %s" % fh.name) */ goto __pyx_L16_break; /* "src/fuse_api.pxi":640 * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: * if line.startswith('Groups:'): # <<<<<<<<<<<<<< * break * else: */ } /* "src/fuse_api.pxi":639 * * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: # <<<<<<<<<<<<<< * if line.startswith('Groups:'): * break */ } /*else*/ { /* "src/fuse_api.pxi":643 * break * else: * raise RuntimeError("Unable to parse %s" % fh.name) # <<<<<<<<<<<<<< * gids = set() * for x in line.split()[1:]: */ __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_fh, __pyx_n_s_name); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 643, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = PyUnicode_Format(__pyx_kp_u_Unable_to_parse_s, __pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 643, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 643, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_GIVEREF(__pyx_t_1); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_RuntimeError, __pyx_t_2, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 643, __pyx_L7_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_Raise(__pyx_t_1, 0, 0, 0); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __PYX_ERR(3, 643, __pyx_L7_error) } /* "src/fuse_api.pxi":639 * * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: # <<<<<<<<<<<<<< * if line.startswith('Groups:'): * break */ __pyx_L16_break:; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; /* "src/fuse_api.pxi":638 * ''' * * with open('/proc/%d/status' % pid, 'r') as fh: # <<<<<<<<<<<<<< * for line in fh: * if line.startswith('Groups:'): */ } __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0; __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0; __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0; goto __pyx_L14_try_end; __pyx_L7_error:; __Pyx_PyThreadState_assign __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0; /*except:*/ { __Pyx_AddTraceback("llfuse.get_sup_groups", __pyx_clineno, __pyx_lineno, __pyx_filename); if (__Pyx_GetException(&__pyx_t_4, &__pyx_t_1, &__pyx_t_2) < 0) __PYX_ERR(3, 638, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_GOTREF(__pyx_t_1); __Pyx_GOTREF(__pyx_t_2); __pyx_t_5 = PyTuple_Pack(3, __pyx_t_4, __pyx_t_1, __pyx_t_2); if (unlikely(!__pyx_t_5)) __PYX_ERR(3, 638, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_5); __pyx_t_12 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_5, NULL); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; if (unlikely(!__pyx_t_12)) __PYX_ERR(3, 638, __pyx_L9_except_error) __Pyx_GOTREF(__pyx_t_12); __pyx_t_11 = __Pyx_PyObject_IsTrue(__pyx_t_12); __Pyx_DECREF(__pyx_t_12); __pyx_t_12 = 0; if (__pyx_t_11 < 0) __PYX_ERR(3, 638, __pyx_L9_except_error) __pyx_t_13 = ((!(__pyx_t_11 != 0)) != 0); if (__pyx_t_13) { __Pyx_GIVEREF(__pyx_t_4); __Pyx_GIVEREF(__pyx_t_1); __Pyx_XGIVEREF(__pyx_t_2); __Pyx_ErrRestoreWithState(__pyx_t_4, __pyx_t_1, __pyx_t_2); __pyx_t_4 = 0; __pyx_t_1 = 0; __pyx_t_2 = 0; __PYX_ERR(3, 638, __pyx_L9_except_error) } __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; goto __pyx_L8_exception_handled; } __pyx_L9_except_error:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_8); __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8); goto __pyx_L1_error; __pyx_L8_exception_handled:; __Pyx_PyThreadState_assign __Pyx_XGIVEREF(__pyx_t_6); __Pyx_XGIVEREF(__pyx_t_7); __Pyx_XGIVEREF(__pyx_t_8); __Pyx_ExceptionReset(__pyx_t_6, __pyx_t_7, __pyx_t_8); __pyx_L14_try_end:; } } /*finally:*/ { /*normal exit:*/{ if (__pyx_t_3) { __pyx_t_8 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple__83, NULL); __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_8); __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0; } goto __pyx_L6; } __pyx_L6:; } goto __pyx_L22; __pyx_L3_error:; __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0; goto __pyx_L1_error; __pyx_L22:; } /* "src/fuse_api.pxi":644 * else: * raise RuntimeError("Unable to parse %s" % fh.name) * gids = set() # <<<<<<<<<<<<<< * for x in line.split()[1:]: * gids.add(int(x)) */ __pyx_t_2 = PySet_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 644, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_v_gids = ((PyObject*)__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":645 * raise RuntimeError("Unable to parse %s" % fh.name) * gids = set() * for x in line.split()[1:]: # <<<<<<<<<<<<<< * gids.add(int(x)) * */ if (unlikely(!__pyx_v_line)) { __Pyx_RaiseUnboundLocalError("line"); __PYX_ERR(3, 645, __pyx_L1_error) } __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_line, __pyx_n_s_split); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_1, function); } } if (__pyx_t_4) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 645, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_PyObject_GetSlice(__pyx_t_2, 1, 0, NULL, NULL, &__pyx_slice__84, 1, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) { __pyx_t_2 = __pyx_t_1; __Pyx_INCREF(__pyx_t_2); __pyx_t_9 = 0; __pyx_t_10 = NULL; } else { __pyx_t_9 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_10 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_10)) __PYX_ERR(3, 645, __pyx_L1_error) } __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; for (;;) { if (likely(!__pyx_t_10)) { if (likely(PyList_CheckExact(__pyx_t_2))) { if (__pyx_t_9 >= PyList_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_1 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_9); __Pyx_INCREF(__pyx_t_1); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(3, 645, __pyx_L1_error) #else __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } else { if (__pyx_t_9 >= PyTuple_GET_SIZE(__pyx_t_2)) break; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_9); __Pyx_INCREF(__pyx_t_1); __pyx_t_9++; if (unlikely(0 < 0)) __PYX_ERR(3, 645, __pyx_L1_error) #else __pyx_t_1 = PySequence_ITEM(__pyx_t_2, __pyx_t_9); __pyx_t_9++; if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); #endif } } else { __pyx_t_1 = __pyx_t_10(__pyx_t_2); if (unlikely(!__pyx_t_1)) { PyObject* exc_type = PyErr_Occurred(); if (exc_type) { if (likely(exc_type == PyExc_StopIteration || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear(); else __PYX_ERR(3, 645, __pyx_L1_error) } break; } __Pyx_GOTREF(__pyx_t_1); } __Pyx_XDECREF_SET(__pyx_v_x, __pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":646 * gids = set() * for x in line.split()[1:]: * gids.add(int(x)) # <<<<<<<<<<<<<< * * return gids */ __pyx_t_1 = __Pyx_PyNumber_Int(__pyx_v_x); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 646, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_14 = PySet_Add(__pyx_v_gids, __pyx_t_1); if (unlikely(__pyx_t_14 == -1)) __PYX_ERR(3, 646, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":645 * raise RuntimeError("Unable to parse %s" % fh.name) * gids = set() * for x in line.split()[1:]: # <<<<<<<<<<<<<< * gids.add(int(x)) * */ } __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":648 * gids.add(int(x)) * * return gids # <<<<<<<<<<<<<< */ __Pyx_XDECREF(__pyx_r); __Pyx_INCREF(__pyx_v_gids); __pyx_r = __pyx_v_gids; goto __pyx_L0; /* "src/fuse_api.pxi":628 * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * * def get_sup_groups(pid): # <<<<<<<<<<<<<< * '''Return supplementary group ids of *pid* * */ /* function exit code */ __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); __Pyx_AddTraceback("llfuse.get_sup_groups", __pyx_clineno, __pyx_lineno, __pyx_filename); __pyx_r = NULL; __pyx_L0:; __Pyx_XDECREF(__pyx_v_fh); __Pyx_XDECREF(__pyx_v_line); __Pyx_XDECREF(__pyx_v_gids); __Pyx_XDECREF(__pyx_v_x); __Pyx_XGIVEREF(__pyx_r); __Pyx_RefNannyFinishContext(); return __pyx_r; } static PyObject *__pyx_tp_new_6llfuse_Lock(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; return o; } static void __pyx_tp_dealloc_6llfuse_Lock(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif (*Py_TYPE(o)->tp_free)(o); } static PyMethodDef __pyx_methods_6llfuse_Lock[] = { {"acquire", (PyCFunction)__pyx_pw_6llfuse_4Lock_3acquire, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_4Lock_2acquire}, {"release", (PyCFunction)__pyx_pw_6llfuse_4Lock_5release, METH_NOARGS, __pyx_doc_6llfuse_4Lock_4release}, {"yield_", (PyCFunction)__pyx_pw_6llfuse_4Lock_7yield_, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_4Lock_6yield_}, {"__enter__", (PyCFunction)__pyx_pw_6llfuse_4Lock_9__enter__, METH_NOARGS, __pyx_doc_6llfuse_4Lock_8__enter__}, {"__exit__", (PyCFunction)__pyx_pw_6llfuse_4Lock_11__exit__, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_4Lock_10__exit__}, {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_4Lock_13__getstate__, METH_NOARGS, __pyx_doc_6llfuse_4Lock_12__getstate__}, {0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_Lock = { PyVarObject_HEAD_INIT(0, 0) "llfuse.Lock", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_Lock), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_Lock, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ "Lock()\n\n This is the class of lock itself as well as a context manager to\n execute code while the global lock is being held.\n ", /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_Lock, /*tp_methods*/ 0, /*tp_members*/ 0, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ __pyx_pw_6llfuse_4Lock_1__init__, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_Lock, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static PyObject *__pyx_tp_new_6llfuse_NoLockManager(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; return o; } static void __pyx_tp_dealloc_6llfuse_NoLockManager(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif (*Py_TYPE(o)->tp_free)(o); } static PyMethodDef __pyx_methods_6llfuse_NoLockManager[] = { {"__enter__", (PyCFunction)__pyx_pw_6llfuse_13NoLockManager_3__enter__, METH_NOARGS, __pyx_doc_6llfuse_13NoLockManager_2__enter__}, {"__exit__", (PyCFunction)__pyx_pw_6llfuse_13NoLockManager_5__exit__, METH_VARARGS|METH_KEYWORDS, __pyx_doc_6llfuse_13NoLockManager_4__exit__}, {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_13NoLockManager_7__getstate__, METH_NOARGS, __pyx_doc_6llfuse_13NoLockManager_6__getstate__}, {0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_NoLockManager = { PyVarObject_HEAD_INIT(0, 0) "llfuse.NoLockManager", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_NoLockManager), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_NoLockManager, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ "NoLockManager()\nContext manager to execute code while the global lock is released", /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_NoLockManager, /*tp_methods*/ 0, /*tp_members*/ 0, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ __pyx_pw_6llfuse_13NoLockManager_1__init__, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_NoLockManager, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static struct __pyx_obj_6llfuse_RequestContext *__pyx_freelist_6llfuse_RequestContext[10]; static int __pyx_freecount_6llfuse_RequestContext = 0; static PyObject *__pyx_tp_new_6llfuse_RequestContext(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_6llfuse_RequestContext > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_RequestContext)) & ((t->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { o = (PyObject*)__pyx_freelist_6llfuse_RequestContext[--__pyx_freecount_6llfuse_RequestContext]; memset(o, 0, sizeof(struct __pyx_obj_6llfuse_RequestContext)); (void) PyObject_INIT(o, t); } else { if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; } return o; } static void __pyx_tp_dealloc_6llfuse_RequestContext(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_6llfuse_RequestContext < 10) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_RequestContext)) & ((Py_TYPE(o)->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { __pyx_freelist_6llfuse_RequestContext[__pyx_freecount_6llfuse_RequestContext++] = ((struct __pyx_obj_6llfuse_RequestContext *)o); } else { (*Py_TYPE(o)->tp_free)(o); } } static PyObject *__pyx_getprop_6llfuse_14RequestContext_uid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_14RequestContext_3uid_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_14RequestContext_pid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_14RequestContext_3pid_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_14RequestContext_gid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_14RequestContext_3gid_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_14RequestContext_umask(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_14RequestContext_5umask_1__get__(o); } static PyMethodDef __pyx_methods_6llfuse_RequestContext[] = { {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_14RequestContext_1__getstate__, METH_NOARGS, __pyx_doc_6llfuse_14RequestContext___getstate__}, {0, 0, 0, 0} }; static struct PyGetSetDef __pyx_getsets_6llfuse_RequestContext[] = { {(char *)"uid", __pyx_getprop_6llfuse_14RequestContext_uid, 0, (char *)0, 0}, {(char *)"pid", __pyx_getprop_6llfuse_14RequestContext_pid, 0, (char *)0, 0}, {(char *)"gid", __pyx_getprop_6llfuse_14RequestContext_gid, 0, (char *)0, 0}, {(char *)"umask", __pyx_getprop_6llfuse_14RequestContext_umask, 0, (char *)0, 0}, {0, 0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_RequestContext = { PyVarObject_HEAD_INIT(0, 0) "llfuse.RequestContext", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_RequestContext), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_RequestContext, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ "\n Instances of this class are passed to some `Operations` methods to\n provide information about the caller of the syscall that initiated\n the request.\n ", /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_RequestContext, /*tp_methods*/ 0, /*tp_members*/ __pyx_getsets_6llfuse_RequestContext, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_RequestContext, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static struct __pyx_obj_6llfuse_SetattrFields *__pyx_freelist_6llfuse_SetattrFields[10]; static int __pyx_freecount_6llfuse_SetattrFields = 0; static PyObject *__pyx_tp_new_6llfuse_SetattrFields(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { struct __pyx_obj_6llfuse_SetattrFields *p; PyObject *o; if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_6llfuse_SetattrFields > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_SetattrFields)) & ((t->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { o = (PyObject*)__pyx_freelist_6llfuse_SetattrFields[--__pyx_freecount_6llfuse_SetattrFields]; memset(o, 0, sizeof(struct __pyx_obj_6llfuse_SetattrFields)); (void) PyObject_INIT(o, t); PyObject_GC_Track(o); } else { if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; } p = ((struct __pyx_obj_6llfuse_SetattrFields *)o); p->update_atime = Py_None; Py_INCREF(Py_None); p->update_mtime = Py_None; Py_INCREF(Py_None); p->update_mode = Py_None; Py_INCREF(Py_None); p->update_uid = Py_None; Py_INCREF(Py_None); p->update_gid = Py_None; Py_INCREF(Py_None); p->update_size = Py_None; Py_INCREF(Py_None); if (unlikely(__pyx_pw_6llfuse_13SetattrFields_1__cinit__(o, __pyx_empty_tuple, NULL) < 0)) goto bad; return o; bad: Py_DECREF(o); o = 0; return NULL; } static void __pyx_tp_dealloc_6llfuse_SetattrFields(PyObject *o) { struct __pyx_obj_6llfuse_SetattrFields *p = (struct __pyx_obj_6llfuse_SetattrFields *)o; #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif PyObject_GC_UnTrack(o); Py_CLEAR(p->update_atime); Py_CLEAR(p->update_mtime); Py_CLEAR(p->update_mode); Py_CLEAR(p->update_uid); Py_CLEAR(p->update_gid); Py_CLEAR(p->update_size); if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_6llfuse_SetattrFields < 10) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_SetattrFields)) & ((Py_TYPE(o)->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { __pyx_freelist_6llfuse_SetattrFields[__pyx_freecount_6llfuse_SetattrFields++] = ((struct __pyx_obj_6llfuse_SetattrFields *)o); } else { (*Py_TYPE(o)->tp_free)(o); } } static int __pyx_tp_traverse_6llfuse_SetattrFields(PyObject *o, visitproc v, void *a) { int e; struct __pyx_obj_6llfuse_SetattrFields *p = (struct __pyx_obj_6llfuse_SetattrFields *)o; if (p->update_atime) { e = (*v)(p->update_atime, a); if (e) return e; } if (p->update_mtime) { e = (*v)(p->update_mtime, a); if (e) return e; } if (p->update_mode) { e = (*v)(p->update_mode, a); if (e) return e; } if (p->update_uid) { e = (*v)(p->update_uid, a); if (e) return e; } if (p->update_gid) { e = (*v)(p->update_gid, a); if (e) return e; } if (p->update_size) { e = (*v)(p->update_size, a); if (e) return e; } return 0; } static int __pyx_tp_clear_6llfuse_SetattrFields(PyObject *o) { PyObject* tmp; struct __pyx_obj_6llfuse_SetattrFields *p = (struct __pyx_obj_6llfuse_SetattrFields *)o; tmp = ((PyObject*)p->update_atime); p->update_atime = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); tmp = ((PyObject*)p->update_mtime); p->update_mtime = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); tmp = ((PyObject*)p->update_mode); p->update_mode = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); tmp = ((PyObject*)p->update_uid); p->update_uid = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); tmp = ((PyObject*)p->update_gid); p->update_gid = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); tmp = ((PyObject*)p->update_size); p->update_size = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); return 0; } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_atime(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_12update_atime_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_mtime(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_12update_mtime_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_mode(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_11update_mode_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_uid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_10update_uid_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_gid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_10update_gid_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_13SetattrFields_update_size(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_13SetattrFields_11update_size_1__get__(o); } static PyMethodDef __pyx_methods_6llfuse_SetattrFields[] = { {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_13SetattrFields_3__getstate__, METH_NOARGS, __pyx_doc_6llfuse_13SetattrFields_2__getstate__}, {0, 0, 0, 0} }; static struct PyGetSetDef __pyx_getsets_6llfuse_SetattrFields[] = { {(char *)"update_atime", __pyx_getprop_6llfuse_13SetattrFields_update_atime, 0, (char *)0, 0}, {(char *)"update_mtime", __pyx_getprop_6llfuse_13SetattrFields_update_mtime, 0, (char *)0, 0}, {(char *)"update_mode", __pyx_getprop_6llfuse_13SetattrFields_update_mode, 0, (char *)0, 0}, {(char *)"update_uid", __pyx_getprop_6llfuse_13SetattrFields_update_uid, 0, (char *)0, 0}, {(char *)"update_gid", __pyx_getprop_6llfuse_13SetattrFields_update_gid, 0, (char *)0, 0}, {(char *)"update_size", __pyx_getprop_6llfuse_13SetattrFields_update_size, 0, (char *)0, 0}, {0, 0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_SetattrFields = { PyVarObject_HEAD_INIT(0, 0) "llfuse.SetattrFields", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_SetattrFields), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_SetattrFields, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "\n `SetattrFields` instances are passed to the `~Operations.setattr` handler\n to specify which attributes should be updated.\n ", /*tp_doc*/ __pyx_tp_traverse_6llfuse_SetattrFields, /*tp_traverse*/ __pyx_tp_clear_6llfuse_SetattrFields, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_SetattrFields, /*tp_methods*/ 0, /*tp_members*/ __pyx_getsets_6llfuse_SetattrFields, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_SetattrFields, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static struct __pyx_obj_6llfuse_EntryAttributes *__pyx_freelist_6llfuse_EntryAttributes[30]; static int __pyx_freecount_6llfuse_EntryAttributes = 0; static PyObject *__pyx_tp_new_6llfuse_EntryAttributes(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_6llfuse_EntryAttributes > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_EntryAttributes)) & ((t->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { o = (PyObject*)__pyx_freelist_6llfuse_EntryAttributes[--__pyx_freecount_6llfuse_EntryAttributes]; memset(o, 0, sizeof(struct __pyx_obj_6llfuse_EntryAttributes)); (void) PyObject_INIT(o, t); } else { if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; } if (unlikely(__pyx_pw_6llfuse_15EntryAttributes_1__cinit__(o, __pyx_empty_tuple, NULL) < 0)) goto bad; return o; bad: Py_DECREF(o); o = 0; return NULL; } static void __pyx_tp_dealloc_6llfuse_EntryAttributes(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_6llfuse_EntryAttributes < 30) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_EntryAttributes)) & ((Py_TYPE(o)->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { __pyx_freelist_6llfuse_EntryAttributes[__pyx_freecount_6llfuse_EntryAttributes++] = ((struct __pyx_obj_6llfuse_EntryAttributes *)o); } else { (*Py_TYPE(o)->tp_free)(o); } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_ino(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_6st_ino_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_ino(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_6st_ino_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_generation(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_10generation_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_generation(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_10generation_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_attr_timeout(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_attr_timeout(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_12attr_timeout_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_entry_timeout(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_entry_timeout(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_13entry_timeout_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_mode(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_7st_mode_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_mode(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_7st_mode_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_nlink(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_8st_nlink_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_nlink(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_8st_nlink_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_uid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_6st_uid_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_uid(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_6st_uid_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_gid(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_6st_gid_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_gid(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_6st_gid_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_rdev(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_7st_rdev_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_rdev(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_7st_rdev_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_size(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_7st_size_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_size(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_7st_size_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_blocks(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_9st_blocks_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_blocks(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_9st_blocks_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_blksize(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_10st_blksize_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_blksize(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_10st_blksize_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_atime_ns(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_atime_ns(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_11st_atime_ns_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_mtime_ns(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_mtime_ns(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_11st_mtime_ns_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_ctime_ns(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_ctime_ns(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_11st_ctime_ns_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_15EntryAttributes_st_birthtime_ns(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_1__get__(o); } static int __pyx_setprop_6llfuse_15EntryAttributes_st_birthtime_ns(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_15EntryAttributes_15st_birthtime_ns_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyMethodDef __pyx_methods_6llfuse_EntryAttributes[] = { {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_15EntryAttributes_3__getstate__, METH_NOARGS, __pyx_doc_6llfuse_15EntryAttributes_2__getstate__}, {"__setstate__", (PyCFunction)__pyx_pw_6llfuse_15EntryAttributes_5__setstate__, METH_O, __pyx_doc_6llfuse_15EntryAttributes_4__setstate__}, {0, 0, 0, 0} }; static struct PyGetSetDef __pyx_getsets_6llfuse_EntryAttributes[] = { {(char *)"st_ino", __pyx_getprop_6llfuse_15EntryAttributes_st_ino, __pyx_setprop_6llfuse_15EntryAttributes_st_ino, (char *)0, 0}, {(char *)"generation", __pyx_getprop_6llfuse_15EntryAttributes_generation, __pyx_setprop_6llfuse_15EntryAttributes_generation, (char *)"The inode generation number", 0}, {(char *)"attr_timeout", __pyx_getprop_6llfuse_15EntryAttributes_attr_timeout, __pyx_setprop_6llfuse_15EntryAttributes_attr_timeout, (char *)"Validity timeout for the attributes of the directory entry\n\n Floating point numbers may be used. Units are seconds.\n ", 0}, {(char *)"entry_timeout", __pyx_getprop_6llfuse_15EntryAttributes_entry_timeout, __pyx_setprop_6llfuse_15EntryAttributes_entry_timeout, (char *)"Validity timeout for the name/existence of the directory entry\n\n Floating point numbers may be used. Units are seconds.\n ", 0}, {(char *)"st_mode", __pyx_getprop_6llfuse_15EntryAttributes_st_mode, __pyx_setprop_6llfuse_15EntryAttributes_st_mode, (char *)0, 0}, {(char *)"st_nlink", __pyx_getprop_6llfuse_15EntryAttributes_st_nlink, __pyx_setprop_6llfuse_15EntryAttributes_st_nlink, (char *)0, 0}, {(char *)"st_uid", __pyx_getprop_6llfuse_15EntryAttributes_st_uid, __pyx_setprop_6llfuse_15EntryAttributes_st_uid, (char *)0, 0}, {(char *)"st_gid", __pyx_getprop_6llfuse_15EntryAttributes_st_gid, __pyx_setprop_6llfuse_15EntryAttributes_st_gid, (char *)0, 0}, {(char *)"st_rdev", __pyx_getprop_6llfuse_15EntryAttributes_st_rdev, __pyx_setprop_6llfuse_15EntryAttributes_st_rdev, (char *)0, 0}, {(char *)"st_size", __pyx_getprop_6llfuse_15EntryAttributes_st_size, __pyx_setprop_6llfuse_15EntryAttributes_st_size, (char *)0, 0}, {(char *)"st_blocks", __pyx_getprop_6llfuse_15EntryAttributes_st_blocks, __pyx_setprop_6llfuse_15EntryAttributes_st_blocks, (char *)0, 0}, {(char *)"st_blksize", __pyx_getprop_6llfuse_15EntryAttributes_st_blksize, __pyx_setprop_6llfuse_15EntryAttributes_st_blksize, (char *)0, 0}, {(char *)"st_atime_ns", __pyx_getprop_6llfuse_15EntryAttributes_st_atime_ns, __pyx_setprop_6llfuse_15EntryAttributes_st_atime_ns, (char *)"Time of last access in (integer) nanoseconds", 0}, {(char *)"st_mtime_ns", __pyx_getprop_6llfuse_15EntryAttributes_st_mtime_ns, __pyx_setprop_6llfuse_15EntryAttributes_st_mtime_ns, (char *)"Time of last modification in (integer) nanoseconds", 0}, {(char *)"st_ctime_ns", __pyx_getprop_6llfuse_15EntryAttributes_st_ctime_ns, __pyx_setprop_6llfuse_15EntryAttributes_st_ctime_ns, (char *)"Time of last inode modification in (integer) nanoseconds", 0}, {(char *)"st_birthtime_ns", __pyx_getprop_6llfuse_15EntryAttributes_st_birthtime_ns, __pyx_setprop_6llfuse_15EntryAttributes_st_birthtime_ns, (char *)"Time of inode creation in (integer) nanoseconds.\n\n Only available under BSD and OS X. Will be zero on Linux.\n ", 0}, {0, 0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_EntryAttributes = { PyVarObject_HEAD_INIT(0, 0) "llfuse.EntryAttributes", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_EntryAttributes), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_EntryAttributes, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ "\n Instances of this class store attributes of directory entries.\n Most of the attributes correspond to the elements of the ``stat``\n C struct as returned by e.g. ``fstat`` and should be\n self-explanatory.\n ", /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_EntryAttributes, /*tp_methods*/ 0, /*tp_members*/ __pyx_getsets_6llfuse_EntryAttributes, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_EntryAttributes, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static struct __pyx_obj_6llfuse_StatvfsData *__pyx_freelist_6llfuse_StatvfsData[1]; static int __pyx_freecount_6llfuse_StatvfsData = 0; static PyObject *__pyx_tp_new_6llfuse_StatvfsData(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_6llfuse_StatvfsData > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_StatvfsData)) & ((t->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { o = (PyObject*)__pyx_freelist_6llfuse_StatvfsData[--__pyx_freecount_6llfuse_StatvfsData]; memset(o, 0, sizeof(struct __pyx_obj_6llfuse_StatvfsData)); (void) PyObject_INIT(o, t); } else { if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; } if (unlikely(__pyx_pw_6llfuse_11StatvfsData_1__cinit__(o, __pyx_empty_tuple, NULL) < 0)) goto bad; return o; bad: Py_DECREF(o); o = 0; return NULL; } static void __pyx_tp_dealloc_6llfuse_StatvfsData(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_6llfuse_StatvfsData < 1) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_StatvfsData)) & ((Py_TYPE(o)->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { __pyx_freelist_6llfuse_StatvfsData[__pyx_freecount_6llfuse_StatvfsData++] = ((struct __pyx_obj_6llfuse_StatvfsData *)o); } else { (*Py_TYPE(o)->tp_free)(o); } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_bsize(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_7f_bsize_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_bsize(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_7f_bsize_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_frsize(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_8f_frsize_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_frsize(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_8f_frsize_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_blocks(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_8f_blocks_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_blocks(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_8f_blocks_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_bfree(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_7f_bfree_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_bfree(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_7f_bfree_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_bavail(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_8f_bavail_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_bavail(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_8f_bavail_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_files(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_7f_files_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_files(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_7f_files_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_ffree(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_7f_ffree_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_ffree(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_7f_ffree_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_favail(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_8f_favail_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_favail(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_8f_favail_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyObject *__pyx_getprop_6llfuse_11StatvfsData_f_namemax(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_11StatvfsData_9f_namemax_1__get__(o); } static int __pyx_setprop_6llfuse_11StatvfsData_f_namemax(PyObject *o, PyObject *v, CYTHON_UNUSED void *x) { if (v) { return __pyx_pw_6llfuse_11StatvfsData_9f_namemax_3__set__(o, v); } else { PyErr_SetString(PyExc_NotImplementedError, "__del__"); return -1; } } static PyMethodDef __pyx_methods_6llfuse_StatvfsData[] = { {"__getstate__", (PyCFunction)__pyx_pw_6llfuse_11StatvfsData_3__getstate__, METH_NOARGS, __pyx_doc_6llfuse_11StatvfsData_2__getstate__}, {"__setstate__", (PyCFunction)__pyx_pw_6llfuse_11StatvfsData_5__setstate__, METH_O, __pyx_doc_6llfuse_11StatvfsData_4__setstate__}, {0, 0, 0, 0} }; static struct PyGetSetDef __pyx_getsets_6llfuse_StatvfsData[] = { {(char *)"f_bsize", __pyx_getprop_6llfuse_11StatvfsData_f_bsize, __pyx_setprop_6llfuse_11StatvfsData_f_bsize, (char *)0, 0}, {(char *)"f_frsize", __pyx_getprop_6llfuse_11StatvfsData_f_frsize, __pyx_setprop_6llfuse_11StatvfsData_f_frsize, (char *)0, 0}, {(char *)"f_blocks", __pyx_getprop_6llfuse_11StatvfsData_f_blocks, __pyx_setprop_6llfuse_11StatvfsData_f_blocks, (char *)0, 0}, {(char *)"f_bfree", __pyx_getprop_6llfuse_11StatvfsData_f_bfree, __pyx_setprop_6llfuse_11StatvfsData_f_bfree, (char *)0, 0}, {(char *)"f_bavail", __pyx_getprop_6llfuse_11StatvfsData_f_bavail, __pyx_setprop_6llfuse_11StatvfsData_f_bavail, (char *)0, 0}, {(char *)"f_files", __pyx_getprop_6llfuse_11StatvfsData_f_files, __pyx_setprop_6llfuse_11StatvfsData_f_files, (char *)0, 0}, {(char *)"f_ffree", __pyx_getprop_6llfuse_11StatvfsData_f_ffree, __pyx_setprop_6llfuse_11StatvfsData_f_ffree, (char *)0, 0}, {(char *)"f_favail", __pyx_getprop_6llfuse_11StatvfsData_f_favail, __pyx_setprop_6llfuse_11StatvfsData_f_favail, (char *)0, 0}, {(char *)"f_namemax", __pyx_getprop_6llfuse_11StatvfsData_f_namemax, __pyx_setprop_6llfuse_11StatvfsData_f_namemax, (char *)0, 0}, {0, 0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_StatvfsData = { PyVarObject_HEAD_INIT(0, 0) "llfuse.StatvfsData", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_StatvfsData), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_StatvfsData, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ "\n Instances of this class store information about the file system.\n The attributes correspond to the elements of the ``statvfs``\n struct, see :manpage:`statvfs(2)` for details.\n ", /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_StatvfsData, /*tp_methods*/ 0, /*tp_members*/ __pyx_getsets_6llfuse_StatvfsData, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_StatvfsData, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static PyObject *__pyx_tp_new_6llfuse_FUSEError(PyTypeObject *t, PyObject *a, PyObject *k) { PyObject *o = (&((PyTypeObject*)PyExc_Exception)[0])->tp_new(t, a, k); if (unlikely(!o)) return 0; if (unlikely(__pyx_pw_6llfuse_9FUSEError_1__cinit__(o, a, k) < 0)) goto bad; return o; bad: Py_DECREF(o); o = 0; return NULL; } static void __pyx_tp_dealloc_6llfuse_FUSEError(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif PyObject_GC_UnTrack(o); PyObject_GC_Track(o); (&((PyTypeObject*)PyExc_Exception)[0])->tp_dealloc(o); } static int __pyx_tp_traverse_6llfuse_FUSEError(PyObject *o, visitproc v, void *a) { int e; if (!(&((PyTypeObject*)PyExc_Exception)[0])->tp_traverse); else { e = (&((PyTypeObject*)PyExc_Exception)[0])->tp_traverse(o,v,a); if (e) return e; } return 0; } static int __pyx_tp_clear_6llfuse_FUSEError(PyObject *o) { if (!(&((PyTypeObject*)PyExc_Exception)[0])->tp_clear); else (&((PyTypeObject*)PyExc_Exception)[0])->tp_clear(o); return 0; } static PyObject *__pyx_getprop_6llfuse_9FUSEError_errno(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_9FUSEError_5errno_1__get__(o); } static PyObject *__pyx_getprop_6llfuse_9FUSEError_errno_(PyObject *o, CYTHON_UNUSED void *x) { return __pyx_pw_6llfuse_9FUSEError_6errno__1__get__(o); } static PyMethodDef __pyx_methods_6llfuse_FUSEError[] = { {0, 0, 0, 0} }; static struct PyGetSetDef __pyx_getsets_6llfuse_FUSEError[] = { {(char *)"errno", __pyx_getprop_6llfuse_9FUSEError_errno, 0, (char *)"Error code to return to client process", 0}, {(char *)"errno_", __pyx_getprop_6llfuse_9FUSEError_errno_, 0, (char *)0, 0}, {0, 0, 0, 0, 0} }; static PyTypeObject __pyx_type_6llfuse_FUSEError = { PyVarObject_HEAD_INIT(0, 0) "llfuse.FUSEError", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_FUSEError), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_FUSEError, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ __pyx_pw_6llfuse_9FUSEError_3__str__, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ "\n This exception may be raised by request handlers to indicate that\n the requested operation could not be carried out. The system call\n that resulted in the request (if any) will then fail with error\n code *errno_*.\n ", /*tp_doc*/ __pyx_tp_traverse_6llfuse_FUSEError, /*tp_traverse*/ __pyx_tp_clear_6llfuse_FUSEError, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ __pyx_methods_6llfuse_FUSEError, /*tp_methods*/ 0, /*tp_members*/ __pyx_getsets_6llfuse_FUSEError, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_FUSEError, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static struct __pyx_obj_6llfuse_NotifyRequest *__pyx_freelist_6llfuse_NotifyRequest[300]; static int __pyx_freecount_6llfuse_NotifyRequest = 0; static PyObject *__pyx_tp_new_6llfuse_NotifyRequest(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { struct __pyx_obj_6llfuse_NotifyRequest *p; PyObject *o; if (CYTHON_COMPILING_IN_CPYTHON && likely((__pyx_freecount_6llfuse_NotifyRequest > 0) & (t->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_NotifyRequest)) & ((t->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { o = (PyObject*)__pyx_freelist_6llfuse_NotifyRequest[--__pyx_freecount_6llfuse_NotifyRequest]; memset(o, 0, sizeof(struct __pyx_obj_6llfuse_NotifyRequest)); (void) PyObject_INIT(o, t); PyObject_GC_Track(o); } else { if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; } p = ((struct __pyx_obj_6llfuse_NotifyRequest *)o); p->name = Py_None; Py_INCREF(Py_None); return o; } static void __pyx_tp_dealloc_6llfuse_NotifyRequest(PyObject *o) { struct __pyx_obj_6llfuse_NotifyRequest *p = (struct __pyx_obj_6llfuse_NotifyRequest *)o; #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif PyObject_GC_UnTrack(o); Py_CLEAR(p->name); if (CYTHON_COMPILING_IN_CPYTHON && ((__pyx_freecount_6llfuse_NotifyRequest < 300) & (Py_TYPE(o)->tp_basicsize == sizeof(struct __pyx_obj_6llfuse_NotifyRequest)) & ((Py_TYPE(o)->tp_flags & (Py_TPFLAGS_IS_ABSTRACT | Py_TPFLAGS_HEAPTYPE)) == 0))) { __pyx_freelist_6llfuse_NotifyRequest[__pyx_freecount_6llfuse_NotifyRequest++] = ((struct __pyx_obj_6llfuse_NotifyRequest *)o); } else { (*Py_TYPE(o)->tp_free)(o); } } static int __pyx_tp_traverse_6llfuse_NotifyRequest(PyObject *o, visitproc v, void *a) { int e; struct __pyx_obj_6llfuse_NotifyRequest *p = (struct __pyx_obj_6llfuse_NotifyRequest *)o; if (p->name) { e = (*v)(p->name, a); if (e) return e; } return 0; } static int __pyx_tp_clear_6llfuse_NotifyRequest(PyObject *o) { PyObject* tmp; struct __pyx_obj_6llfuse_NotifyRequest *p = (struct __pyx_obj_6llfuse_NotifyRequest *)o; tmp = ((PyObject*)p->name); p->name = Py_None; Py_INCREF(Py_None); Py_XDECREF(tmp); return 0; } static PyTypeObject __pyx_type_6llfuse_NotifyRequest = { PyVarObject_HEAD_INIT(0, 0) "llfuse.NotifyRequest", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_NotifyRequest), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_NotifyRequest, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/ 0, /*tp_doc*/ __pyx_tp_traverse_6llfuse_NotifyRequest, /*tp_traverse*/ __pyx_tp_clear_6llfuse_NotifyRequest, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ 0, /*tp_methods*/ 0, /*tp_members*/ 0, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_NotifyRequest, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static PyObject *__pyx_tp_new_6llfuse_VoidPtrCapsule(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) { PyObject *o; if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) { o = (*t->tp_alloc)(t, 0); } else { o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0); } if (unlikely(!o)) return 0; return o; } static void __pyx_tp_dealloc_6llfuse_VoidPtrCapsule(PyObject *o) { #if PY_VERSION_HEX >= 0x030400a1 if (unlikely(Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) { if (PyObject_CallFinalizerFromDealloc(o)) return; } #endif (*Py_TYPE(o)->tp_free)(o); } static PyTypeObject __pyx_type_6llfuse_VoidPtrCapsule = { PyVarObject_HEAD_INIT(0, 0) "llfuse.VoidPtrCapsule", /*tp_name*/ sizeof(struct __pyx_obj_6llfuse_VoidPtrCapsule), /*tp_basicsize*/ 0, /*tp_itemsize*/ __pyx_tp_dealloc_6llfuse_VoidPtrCapsule, /*tp_dealloc*/ 0, /*tp_print*/ 0, /*tp_getattr*/ 0, /*tp_setattr*/ #if PY_MAJOR_VERSION < 3 0, /*tp_compare*/ #endif #if PY_MAJOR_VERSION >= 3 0, /*tp_as_async*/ #endif 0, /*tp_repr*/ 0, /*tp_as_number*/ 0, /*tp_as_sequence*/ 0, /*tp_as_mapping*/ 0, /*tp_hash*/ 0, /*tp_call*/ 0, /*tp_str*/ 0, /*tp_getattro*/ 0, /*tp_setattro*/ 0, /*tp_as_buffer*/ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE, /*tp_flags*/ 0, /*tp_doc*/ 0, /*tp_traverse*/ 0, /*tp_clear*/ 0, /*tp_richcompare*/ 0, /*tp_weaklistoffset*/ 0, /*tp_iter*/ 0, /*tp_iternext*/ 0, /*tp_methods*/ 0, /*tp_members*/ 0, /*tp_getset*/ 0, /*tp_base*/ 0, /*tp_dict*/ 0, /*tp_descr_get*/ 0, /*tp_descr_set*/ 0, /*tp_dictoffset*/ 0, /*tp_init*/ 0, /*tp_alloc*/ __pyx_tp_new_6llfuse_VoidPtrCapsule, /*tp_new*/ 0, /*tp_free*/ 0, /*tp_is_gc*/ 0, /*tp_bases*/ 0, /*tp_mro*/ 0, /*tp_cache*/ 0, /*tp_subclasses*/ 0, /*tp_weaklist*/ 0, /*tp_del*/ 0, /*tp_version_tag*/ #if PY_VERSION_HEX >= 0x030400a1 0, /*tp_finalize*/ #endif }; static PyMethodDef __pyx_methods[] = { {0, 0, 0, 0} }; #if PY_MAJOR_VERSION >= 3 static struct PyModuleDef __pyx_moduledef = { #if PY_VERSION_HEX < 0x03020000 { PyObject_HEAD_INIT(NULL) NULL, 0, NULL }, #else PyModuleDef_HEAD_INIT, #endif "llfuse", __pyx_k_llfuse_pxy_Copyright_2013_Nikol, /* m_doc */ -1, /* m_size */ __pyx_methods /* m_methods */, NULL, /* m_reload */ NULL, /* m_traverse */ NULL, /* m_clear */ NULL /* m_free */ }; #endif static __Pyx_StringTabEntry __pyx_string_tab[] = { {&__pyx_kp_u_, __pyx_k_, sizeof(__pyx_k_), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_lowlevel_new, __pyx_k_Calling_fuse_lowlevel_new, sizeof(__pyx_k_Calling_fuse_lowlevel_new), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_mount, __pyx_k_Calling_fuse_mount, sizeof(__pyx_k_Calling_fuse_mount), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_session_add_chan, __pyx_k_Calling_fuse_session_add_chan, sizeof(__pyx_k_Calling_fuse_session_add_chan), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_session_destroy, __pyx_k_Calling_fuse_session_destroy, sizeof(__pyx_k_Calling_fuse_session_destroy), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_session_loop, __pyx_k_Calling_fuse_session_loop, sizeof(__pyx_k_Calling_fuse_session_loop), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_session_remove_chan, __pyx_k_Calling_fuse_session_remove_chan, sizeof(__pyx_k_Calling_fuse_session_remove_chan), 0, 1, 0, 0}, {&__pyx_kp_u_Calling_fuse_unmount, __pyx_k_Calling_fuse_unmount, sizeof(__pyx_k_Calling_fuse_unmount), 0, 1, 0, 0}, {&__pyx_n_u_Darwin, __pyx_k_Darwin, sizeof(__pyx_k_Darwin), 0, 1, 0, 1}, {&__pyx_n_u_ENOATTR, __pyx_k_ENOATTR, sizeof(__pyx_k_ENOATTR), 0, 1, 0, 1}, {&__pyx_kp_u_Exception_after_kill, __pyx_k_Exception_after_kill, sizeof(__pyx_k_Exception_after_kill), 0, 1, 0, 0}, {&__pyx_n_s_ExitStack, __pyx_k_ExitStack, sizeof(__pyx_k_ExitStack), 0, 0, 1, 1}, {&__pyx_kp_u_FUSE_worker_thread_d_terminated, __pyx_k_FUSE_worker_thread_d_terminated, sizeof(__pyx_k_FUSE_worker_thread_d_terminated), 0, 1, 0, 0}, {&__pyx_kp_u_Global_lock_cannot_be_acquired_m, __pyx_k_Global_lock_cannot_be_acquired_m, sizeof(__pyx_k_Global_lock_cannot_be_acquired_m), 0, 1, 0, 0}, {&__pyx_kp_u_Groups, __pyx_k_Groups, sizeof(__pyx_k_Groups), 0, 1, 0, 0}, {&__pyx_kp_u_Initializing_llfuse, __pyx_k_Initializing_llfuse, sizeof(__pyx_k_Initializing_llfuse), 0, 1, 0, 0}, {&__pyx_kp_u_Lock_can_only_be_released_by_the, __pyx_k_Lock_can_only_be_released_by_the, sizeof(__pyx_k_Lock_can_only_be_released_by_the), 0, 1, 0, 0}, {&__pyx_kp_u_Lock_instances_can_t_be_pickled, __pyx_k_Lock_instances_can_t_be_pickled, sizeof(__pyx_k_Lock_instances_can_t_be_pickled), 0, 1, 0, 0}, {&__pyx_kp_u_Lock_not_initialized, __pyx_k_Lock_not_initialized, sizeof(__pyx_k_Lock_not_initialized), 0, 1, 0, 0}, {&__pyx_kp_u_Lock_still_taken_after_receiving, __pyx_k_Lock_still_taken_after_receiving, sizeof(__pyx_k_Lock_still_taken_after_receiving), 0, 1, 0, 0}, {&__pyx_n_s_MemoryError, __pyx_k_MemoryError, sizeof(__pyx_k_MemoryError), 0, 0, 1, 1}, {&__pyx_kp_u_Need_to_call_init_before_main, __pyx_k_Need_to_call_init_before_main, sizeof(__pyx_k_Need_to_call_init_before_main), 0, 1, 0, 0}, {&__pyx_kp_u_NoLockManager_instances_can_t_be, __pyx_k_NoLockManager_instances_can_t_be, sizeof(__pyx_k_NoLockManager_instances_can_t_be), 0, 1, 0, 0}, {&__pyx_kp_u_No_workers_is_not_a_good_idea, __pyx_k_No_workers_is_not_a_good_idea, sizeof(__pyx_k_No_workers_is_not_a_good_idea), 0, 1, 0, 0}, {&__pyx_n_s_OSError, __pyx_k_OSError, sizeof(__pyx_k_OSError), 0, 0, 1, 1}, {&__pyx_kp_u_Only_one_exception_can_be_re_rai, __pyx_k_Only_one_exception_can_be_re_rai, sizeof(__pyx_k_Only_one_exception_can_be_re_rai), 0, 1, 0, 0}, {&__pyx_kp_u_Only_one_exception_can_be_re_rai_2, __pyx_k_Only_one_exception_can_be_re_rai_2, sizeof(__pyx_k_Only_one_exception_can_be_re_rai_2), 0, 1, 0, 0}, {&__pyx_n_s_Operations, __pyx_k_Operations, sizeof(__pyx_k_Operations), 0, 0, 1, 1}, {&__pyx_n_s_Operations_access, __pyx_k_Operations_access, sizeof(__pyx_k_Operations_access), 0, 0, 1, 1}, {&__pyx_n_s_Operations_create, __pyx_k_Operations_create, sizeof(__pyx_k_Operations_create), 0, 0, 1, 1}, {&__pyx_n_s_Operations_destroy, __pyx_k_Operations_destroy, sizeof(__pyx_k_Operations_destroy), 0, 0, 1, 1}, {&__pyx_n_s_Operations_flush, __pyx_k_Operations_flush, sizeof(__pyx_k_Operations_flush), 0, 0, 1, 1}, {&__pyx_n_s_Operations_forget, __pyx_k_Operations_forget, sizeof(__pyx_k_Operations_forget), 0, 0, 1, 1}, {&__pyx_n_s_Operations_fsync, __pyx_k_Operations_fsync, sizeof(__pyx_k_Operations_fsync), 0, 0, 1, 1}, {&__pyx_n_s_Operations_fsyncdir, __pyx_k_Operations_fsyncdir, sizeof(__pyx_k_Operations_fsyncdir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_getattr, __pyx_k_Operations_getattr, sizeof(__pyx_k_Operations_getattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_getxattr, __pyx_k_Operations_getxattr, sizeof(__pyx_k_Operations_getxattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_init, __pyx_k_Operations_init, sizeof(__pyx_k_Operations_init), 0, 0, 1, 1}, {&__pyx_n_s_Operations_link, __pyx_k_Operations_link, sizeof(__pyx_k_Operations_link), 0, 0, 1, 1}, {&__pyx_n_s_Operations_listxattr, __pyx_k_Operations_listxattr, sizeof(__pyx_k_Operations_listxattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_lookup, __pyx_k_Operations_lookup, sizeof(__pyx_k_Operations_lookup), 0, 0, 1, 1}, {&__pyx_n_s_Operations_mkdir, __pyx_k_Operations_mkdir, sizeof(__pyx_k_Operations_mkdir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_mknod, __pyx_k_Operations_mknod, sizeof(__pyx_k_Operations_mknod), 0, 0, 1, 1}, {&__pyx_n_s_Operations_open, __pyx_k_Operations_open, sizeof(__pyx_k_Operations_open), 0, 0, 1, 1}, {&__pyx_n_s_Operations_opendir, __pyx_k_Operations_opendir, sizeof(__pyx_k_Operations_opendir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_read, __pyx_k_Operations_read, sizeof(__pyx_k_Operations_read), 0, 0, 1, 1}, {&__pyx_n_s_Operations_readdir, __pyx_k_Operations_readdir, sizeof(__pyx_k_Operations_readdir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_readlink, __pyx_k_Operations_readlink, sizeof(__pyx_k_Operations_readlink), 0, 0, 1, 1}, {&__pyx_n_s_Operations_release, __pyx_k_Operations_release, sizeof(__pyx_k_Operations_release), 0, 0, 1, 1}, {&__pyx_n_s_Operations_releasedir, __pyx_k_Operations_releasedir, sizeof(__pyx_k_Operations_releasedir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_removexattr, __pyx_k_Operations_removexattr, sizeof(__pyx_k_Operations_removexattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_rename, __pyx_k_Operations_rename, sizeof(__pyx_k_Operations_rename), 0, 0, 1, 1}, {&__pyx_n_s_Operations_rmdir, __pyx_k_Operations_rmdir, sizeof(__pyx_k_Operations_rmdir), 0, 0, 1, 1}, {&__pyx_n_s_Operations_setattr, __pyx_k_Operations_setattr, sizeof(__pyx_k_Operations_setattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_setxattr, __pyx_k_Operations_setxattr, sizeof(__pyx_k_Operations_setxattr), 0, 0, 1, 1}, {&__pyx_n_s_Operations_stacktrace, __pyx_k_Operations_stacktrace, sizeof(__pyx_k_Operations_stacktrace), 0, 0, 1, 1}, {&__pyx_n_s_Operations_statfs, __pyx_k_Operations_statfs, sizeof(__pyx_k_Operations_statfs), 0, 0, 1, 1}, {&__pyx_n_s_Operations_symlink, __pyx_k_Operations_symlink, sizeof(__pyx_k_Operations_symlink), 0, 0, 1, 1}, {&__pyx_n_s_Operations_unlink, __pyx_k_Operations_unlink, sizeof(__pyx_k_Operations_unlink), 0, 0, 1, 1}, {&__pyx_n_s_Operations_write, __pyx_k_Operations_write, sizeof(__pyx_k_Operations_write), 0, 0, 1, 1}, {&__pyx_kp_u_Other_thread_didn_t_take_lock, __pyx_k_Other_thread_didn_t_take_lock, sizeof(__pyx_k_Other_thread_didn_t_take_lock), 0, 1, 0, 0}, {&__pyx_n_s_OverflowError, __pyx_k_OverflowError, sizeof(__pyx_k_OverflowError), 0, 0, 1, 1}, {&__pyx_n_s_PicklingError, __pyx_k_PicklingError, sizeof(__pyx_k_PicklingError), 0, 0, 1, 1}, {&__pyx_kp_b_Python_LLFUSE, __pyx_k_Python_LLFUSE, sizeof(__pyx_k_Python_LLFUSE), 0, 0, 0, 0}, {&__pyx_n_s_Queue, __pyx_k_Queue, sizeof(__pyx_k_Queue), 0, 0, 1, 1}, {&__pyx_n_s_ROOT_INODE, __pyx_k_ROOT_INODE, sizeof(__pyx_k_ROOT_INODE), 0, 0, 1, 1}, {&__pyx_kp_u_RequestContext_instances_can_t_b, __pyx_k_RequestContext_instances_can_t_b, sizeof(__pyx_k_RequestContext_instances_can_t_b), 0, 1, 0, 0}, {&__pyx_n_s_RuntimeError, __pyx_k_RuntimeError, sizeof(__pyx_k_RuntimeError), 0, 0, 1, 1}, {&__pyx_kp_u_SetattrFields_instances_can_t_be, __pyx_k_SetattrFields_instances_can_t_be, sizeof(__pyx_k_SetattrFields_instances_can_t_be), 0, 1, 0, 0}, {&__pyx_kp_u_Terminated_main_loop_because_req, __pyx_k_Terminated_main_loop_because_req, sizeof(__pyx_k_Terminated_main_loop_because_req), 0, 1, 0, 0}, {&__pyx_kp_s_This_class_defines_the_general, __pyx_k_This_class_defines_the_general, sizeof(__pyx_k_This_class_defines_the_general), 0, 0, 1, 0}, {&__pyx_n_s_Thread, __pyx_k_Thread, sizeof(__pyx_k_Thread), 0, 0, 1, 1}, {&__pyx_kp_u_ThreadID_s, __pyx_k_ThreadID_s, sizeof(__pyx_k_ThreadID_s), 0, 1, 0, 0}, {&__pyx_n_s_TypeError, __pyx_k_TypeError, sizeof(__pyx_k_TypeError), 0, 0, 1, 1}, {&__pyx_kp_u_Unable_to_parse_s, __pyx_k_Unable_to_parse_s, sizeof(__pyx_k_Unable_to_parse_s), 0, 1, 0, 0}, {&__pyx_n_s_ValueError, __pyx_k_ValueError, sizeof(__pyx_k_ValueError), 0, 0, 1, 1}, {&__pyx_kp_u_Value_too_long_to_convert_to_Pyt, __pyx_k_Value_too_long_to_convert_to_Pyt, sizeof(__pyx_k_Value_too_long_to_convert_to_Pyt), 0, 1, 0, 0}, {&__pyx_kp_u_Weird_request_kind_received_d, __pyx_k_Weird_request_kind_received_d, sizeof(__pyx_k_Weird_request_kind_received_d), 0, 1, 0, 0}, {&__pyx_kp_u_You_should_not_instantiate_this, __pyx_k_You_should_not_instantiate_this, sizeof(__pyx_k_You_should_not_instantiate_this), 0, 1, 0, 0}, {&__pyx_kp_b__35, __pyx_k__35, sizeof(__pyx_k__35), 0, 0, 0, 0}, {&__pyx_n_s_abspath, __pyx_k_abspath, sizeof(__pyx_k_abspath), 0, 0, 1, 1}, {&__pyx_n_s_access, __pyx_k_access, sizeof(__pyx_k_access), 0, 0, 1, 1}, {&__pyx_n_s_acquire, __pyx_k_acquire, sizeof(__pyx_k_acquire), 0, 0, 1, 1}, {&__pyx_n_s_attr, __pyx_k_attr, sizeof(__pyx_k_attr), 0, 0, 1, 1}, {&__pyx_n_s_attr_only, __pyx_k_attr_only, sizeof(__pyx_k_attr_only), 0, 0, 1, 1}, {&__pyx_n_u_attr_timeout, __pyx_k_attr_timeout, sizeof(__pyx_k_attr_timeout), 0, 1, 0, 1}, {&__pyx_n_s_basename, __pyx_k_basename, sizeof(__pyx_k_basename), 0, 0, 1, 1}, {&__pyx_n_u_big_writes, __pyx_k_big_writes, sizeof(__pyx_k_big_writes), 0, 1, 0, 1}, {&__pyx_n_s_block, __pyx_k_block, sizeof(__pyx_k_block), 0, 0, 1, 1}, {&__pyx_n_s_buf, __pyx_k_buf, sizeof(__pyx_k_buf), 0, 0, 1, 1}, {&__pyx_n_s_bufsize, __pyx_k_bufsize, sizeof(__pyx_k_bufsize), 0, 0, 1, 1}, {&__pyx_n_s_bufvec, __pyx_k_bufvec, sizeof(__pyx_k_bufvec), 0, 0, 1, 1}, {&__pyx_n_s_callback, __pyx_k_callback, sizeof(__pyx_k_callback), 0, 0, 1, 1}, {&__pyx_n_s_close, __pyx_k_close, sizeof(__pyx_k_close), 0, 0, 1, 1}, {&__pyx_n_s_cname, __pyx_k_cname, sizeof(__pyx_k_cname), 0, 0, 1, 1}, {&__pyx_n_s_cnamespace, __pyx_k_cnamespace, sizeof(__pyx_k_cnamespace), 0, 0, 1, 1}, {&__pyx_n_s_code, __pyx_k_code, sizeof(__pyx_k_code), 0, 0, 1, 1}, {&__pyx_n_s_contextlib, __pyx_k_contextlib, sizeof(__pyx_k_contextlib), 0, 0, 1, 1}, {&__pyx_n_s_contextlib2, __pyx_k_contextlib2, sizeof(__pyx_k_contextlib2), 0, 0, 1, 1}, {&__pyx_n_s_count, __pyx_k_count, sizeof(__pyx_k_count), 0, 0, 1, 1}, {&__pyx_n_s_cpath, __pyx_k_cpath, sizeof(__pyx_k_cpath), 0, 0, 1, 1}, {&__pyx_n_s_create, __pyx_k_create, sizeof(__pyx_k_create), 0, 0, 1, 1}, {&__pyx_n_s_ctx, __pyx_k_ctx, sizeof(__pyx_k_ctx), 0, 0, 1, 1}, {&__pyx_n_s_current_frames, __pyx_k_current_frames, sizeof(__pyx_k_current_frames), 0, 0, 1, 1}, {&__pyx_n_s_current_thread, __pyx_k_current_thread, sizeof(__pyx_k_current_thread), 0, 0, 1, 1}, {&__pyx_n_s_cvalue, __pyx_k_cvalue, sizeof(__pyx_k_cvalue), 0, 0, 1, 1}, {&__pyx_n_s_daemon, __pyx_k_daemon, sizeof(__pyx_k_daemon), 0, 0, 1, 1}, {&__pyx_n_s_data, __pyx_k_data, sizeof(__pyx_k_data), 0, 0, 1, 1}, {&__pyx_n_s_datasync, __pyx_k_datasync, sizeof(__pyx_k_datasync), 0, 0, 1, 1}, {&__pyx_n_s_debug, __pyx_k_debug, sizeof(__pyx_k_debug), 0, 0, 1, 1}, {&__pyx_n_s_decode, __pyx_k_decode, sizeof(__pyx_k_decode), 0, 0, 1, 1}, {&__pyx_n_s_default_options, __pyx_k_default_options, sizeof(__pyx_k_default_options), 0, 0, 1, 1}, {&__pyx_n_u_default_permissions, __pyx_k_default_permissions, sizeof(__pyx_k_default_permissions), 0, 1, 0, 1}, {&__pyx_n_s_destroy, __pyx_k_destroy, sizeof(__pyx_k_destroy), 0, 0, 1, 1}, {&__pyx_n_s_dirp, __pyx_k_dirp, sizeof(__pyx_k_dirp), 0, 0, 1, 1}, {&__pyx_n_s_doc, __pyx_k_doc, sizeof(__pyx_k_doc), 0, 0, 1, 1}, {&__pyx_n_s_encode, __pyx_k_encode, sizeof(__pyx_k_encode), 0, 0, 1, 1}, {&__pyx_n_s_enter, __pyx_k_enter, sizeof(__pyx_k_enter), 0, 0, 1, 1}, {&__pyx_n_u_entry_timeout, __pyx_k_entry_timeout, sizeof(__pyx_k_entry_timeout), 0, 1, 0, 1}, {&__pyx_n_s_enumerate, __pyx_k_enumerate, sizeof(__pyx_k_enumerate), 0, 0, 1, 1}, {&__pyx_n_s_errno, __pyx_k_errno, sizeof(__pyx_k_errno), 0, 0, 1, 1}, {&__pyx_kp_u_errno_d, __pyx_k_errno_d, sizeof(__pyx_k_errno_d), 0, 1, 0, 0}, {&__pyx_n_s_error, __pyx_k_error, sizeof(__pyx_k_error), 0, 0, 1, 1}, {&__pyx_n_s_exc_info, __pyx_k_exc_info, sizeof(__pyx_k_exc_info), 0, 0, 1, 1}, {&__pyx_n_s_exc_tb, __pyx_k_exc_tb, sizeof(__pyx_k_exc_tb), 0, 0, 1, 1}, {&__pyx_n_s_exc_type, __pyx_k_exc_type, sizeof(__pyx_k_exc_type), 0, 0, 1, 1}, {&__pyx_n_s_exc_val, __pyx_k_exc_val, sizeof(__pyx_k_exc_val), 0, 0, 1, 1}, {&__pyx_n_s_exception, __pyx_k_exception, sizeof(__pyx_k_exception), 0, 0, 1, 1}, {&__pyx_n_s_exit, __pyx_k_exit, sizeof(__pyx_k_exit), 0, 0, 1, 1}, {&__pyx_n_s_extract_stack, __pyx_k_extract_stack, sizeof(__pyx_k_extract_stack), 0, 0, 1, 1}, {&__pyx_n_s_f_args, __pyx_k_f_args, sizeof(__pyx_k_f_args), 0, 0, 1, 1}, {&__pyx_n_u_f_bavail, __pyx_k_f_bavail, sizeof(__pyx_k_f_bavail), 0, 1, 0, 1}, {&__pyx_n_u_f_bfree, __pyx_k_f_bfree, sizeof(__pyx_k_f_bfree), 0, 1, 0, 1}, {&__pyx_n_u_f_blocks, __pyx_k_f_blocks, sizeof(__pyx_k_f_blocks), 0, 1, 0, 1}, {&__pyx_n_u_f_bsize, __pyx_k_f_bsize, sizeof(__pyx_k_f_bsize), 0, 1, 0, 1}, {&__pyx_n_u_f_favail, __pyx_k_f_favail, sizeof(__pyx_k_f_favail), 0, 1, 0, 1}, {&__pyx_n_u_f_ffree, __pyx_k_f_ffree, sizeof(__pyx_k_f_ffree), 0, 1, 0, 1}, {&__pyx_n_u_f_files, __pyx_k_f_files, sizeof(__pyx_k_f_files), 0, 1, 0, 1}, {&__pyx_n_u_f_frsize, __pyx_k_f_frsize, sizeof(__pyx_k_f_frsize), 0, 1, 0, 1}, {&__pyx_n_u_f_namemax, __pyx_k_f_namemax, sizeof(__pyx_k_f_namemax), 0, 1, 0, 1}, {&__pyx_n_s_fh, __pyx_k_fh, sizeof(__pyx_k_fh), 0, 0, 1, 1}, {&__pyx_n_s_fields, __pyx_k_fields, sizeof(__pyx_k_fields), 0, 0, 1, 1}, {&__pyx_n_s_filename, __pyx_k_filename, sizeof(__pyx_k_filename), 0, 0, 1, 1}, {&__pyx_n_s_flags, __pyx_k_flags, sizeof(__pyx_k_flags), 0, 0, 1, 1}, {&__pyx_n_s_flush, __pyx_k_flush, sizeof(__pyx_k_flush), 0, 0, 1, 1}, {&__pyx_n_s_forget, __pyx_k_forget, sizeof(__pyx_k_forget), 0, 0, 1, 1}, {&__pyx_n_s_frame, __pyx_k_frame, sizeof(__pyx_k_frame), 0, 0, 1, 1}, {&__pyx_n_s_fse, __pyx_k_fse, sizeof(__pyx_k_fse), 0, 0, 1, 1}, {&__pyx_n_s_fsync, __pyx_k_fsync, sizeof(__pyx_k_fsync), 0, 0, 1, 1}, {&__pyx_n_s_fsyncdir, __pyx_k_fsyncdir, sizeof(__pyx_k_fsyncdir), 0, 0, 1, 1}, {&__pyx_kp_u_fuse_access_fuse_reply__failed_w, __pyx_k_fuse_access_fuse_reply__failed_w, sizeof(__pyx_k_fuse_access_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_buf_copy_failed_with, __pyx_k_fuse_buf_copy_failed_with, sizeof(__pyx_k_fuse_buf_copy_failed_with), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_create_fuse_reply__failed_w, __pyx_k_fuse_create_fuse_reply__failed_w, sizeof(__pyx_k_fuse_create_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_flush_fuse_reply__failed_wi, __pyx_k_fuse_flush_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_flush_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_fsync_fuse_reply__failed_wi, __pyx_k_fuse_fsync_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_fsync_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_fsyncdir_fuse_reply__failed, __pyx_k_fuse_fsyncdir_fuse_reply__failed, sizeof(__pyx_k_fuse_fsyncdir_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_getattr_fuse_reply__failed, __pyx_k_fuse_getattr_fuse_reply__failed, sizeof(__pyx_k_fuse_getattr_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_getxattr_fuse_reply__failed, __pyx_k_fuse_getxattr_fuse_reply__failed, sizeof(__pyx_k_fuse_getxattr_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_getxattr_non_zero_position, __pyx_k_fuse_getxattr_non_zero_position, sizeof(__pyx_k_fuse_getxattr_non_zero_position), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_link_fuse_reply__failed_wit, __pyx_k_fuse_link_fuse_reply__failed_wit, sizeof(__pyx_k_fuse_link_fuse_reply__failed_wit), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_listxattr_fuse_reply__faile, __pyx_k_fuse_listxattr_fuse_reply__faile, sizeof(__pyx_k_fuse_listxattr_fuse_reply__faile), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_lookup_fuse_reply__failed_w, __pyx_k_fuse_lookup_fuse_reply__failed_w, sizeof(__pyx_k_fuse_lookup_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_lowlevel_new_failed, __pyx_k_fuse_lowlevel_new_failed, sizeof(__pyx_k_fuse_lowlevel_new_failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_lowlevel_notify_store_retur, __pyx_k_fuse_lowlevel_notify_store_retur, sizeof(__pyx_k_fuse_lowlevel_notify_store_retur), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_mkdir_fuse_reply__failed_wi, __pyx_k_fuse_mkdir_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_mkdir_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_mknod_fuse_reply__failed_wi, __pyx_k_fuse_mknod_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_mknod_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_mount_failed, __pyx_k_fuse_mount_failed, sizeof(__pyx_k_fuse_mount_failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_opendir_fuse_reply__failed, __pyx_k_fuse_opendir_fuse_reply__failed, sizeof(__pyx_k_fuse_opendir_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_read_fuse_reply__failed_wit, __pyx_k_fuse_read_fuse_reply__failed_wit, sizeof(__pyx_k_fuse_read_fuse_reply__failed_wit), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_readdir_fuse_reply__failed, __pyx_k_fuse_readdir_fuse_reply__failed, sizeof(__pyx_k_fuse_readdir_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_readlink_fuse_reply__failed, __pyx_k_fuse_readlink_fuse_reply__failed, sizeof(__pyx_k_fuse_readlink_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_release_fuse_reply__failed, __pyx_k_fuse_release_fuse_reply__failed, sizeof(__pyx_k_fuse_release_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_releasedir_fuse_reply__fail, __pyx_k_fuse_releasedir_fuse_reply__fail, sizeof(__pyx_k_fuse_releasedir_fuse_reply__fail), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_removexattr_fuse_reply__fai, __pyx_k_fuse_removexattr_fuse_reply__fai, sizeof(__pyx_k_fuse_removexattr_fuse_reply__fai), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_rename_fuse_reply__failed_w, __pyx_k_fuse_rename_fuse_reply__failed_w, sizeof(__pyx_k_fuse_rename_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_rmdir_fuse_reply__failed_wi, __pyx_k_fuse_rmdir_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_rmdir_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_session_receive_buf_failed, __pyx_k_fuse_session_receive_buf_failed, sizeof(__pyx_k_fuse_session_receive_buf_failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_setattr_clock_gettime_CLOCK, __pyx_k_fuse_setattr_clock_gettime_CLOCK, sizeof(__pyx_k_fuse_setattr_clock_gettime_CLOCK), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_setattr_fuse_reply__failed, __pyx_k_fuse_setattr_fuse_reply__failed, sizeof(__pyx_k_fuse_setattr_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_setxattr_fuse_reply__failed, __pyx_k_fuse_setxattr_fuse_reply__failed, sizeof(__pyx_k_fuse_setxattr_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_setxattr_fuse_reply_err_fai, __pyx_k_fuse_setxattr_fuse_reply_err_fai, sizeof(__pyx_k_fuse_setxattr_fuse_reply_err_fai), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_setxattr_non_zero_position, __pyx_k_fuse_setxattr_non_zero_position, sizeof(__pyx_k_fuse_setxattr_non_zero_position), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_statfs_fuse_reply__failed_w, __pyx_k_fuse_statfs_fuse_reply__failed_w, sizeof(__pyx_k_fuse_statfs_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_symlink_fuse_reply__failed, __pyx_k_fuse_symlink_fuse_reply__failed, sizeof(__pyx_k_fuse_symlink_fuse_reply__failed), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_unlink_fuse_reply__failed_w, __pyx_k_fuse_unlink_fuse_reply__failed_w, sizeof(__pyx_k_fuse_unlink_fuse_reply__failed_w), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_worker_d, __pyx_k_fuse_worker_d, sizeof(__pyx_k_fuse_worker_d), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_write_buf_fuse_reply__faile, __pyx_k_fuse_write_buf_fuse_reply__faile, sizeof(__pyx_k_fuse_write_buf_fuse_reply__faile), 0, 1, 0, 0}, {&__pyx_kp_u_fuse_write_fuse_reply__failed_wi, __pyx_k_fuse_write_fuse_reply__failed_wi, sizeof(__pyx_k_fuse_write_fuse_reply__failed_wi), 0, 1, 0, 0}, {&__pyx_n_u_generation, __pyx_k_generation, sizeof(__pyx_k_generation), 0, 1, 0, 1}, {&__pyx_n_s_get, __pyx_k_get, sizeof(__pyx_k_get), 0, 0, 1, 1}, {&__pyx_n_s_getLogger, __pyx_k_getLogger, sizeof(__pyx_k_getLogger), 0, 0, 1, 1}, {&__pyx_n_s_get_ino_t_bits, __pyx_k_get_ino_t_bits, sizeof(__pyx_k_get_ino_t_bits), 0, 0, 1, 1}, {&__pyx_n_s_get_off_t_bits, __pyx_k_get_off_t_bits, sizeof(__pyx_k_get_off_t_bits), 0, 0, 1, 1}, {&__pyx_n_s_get_sup_groups, __pyx_k_get_sup_groups, sizeof(__pyx_k_get_sup_groups), 0, 0, 1, 1}, {&__pyx_n_s_getattr, __pyx_k_getattr, sizeof(__pyx_k_getattr), 0, 0, 1, 1}, {&__pyx_n_s_getfilesystemencoding, __pyx_k_getfilesystemencoding, sizeof(__pyx_k_getfilesystemencoding), 0, 0, 1, 1}, {&__pyx_n_s_getxattr, __pyx_k_getxattr, sizeof(__pyx_k_getxattr), 0, 0, 1, 1}, {&__pyx_n_s_gids, __pyx_k_gids, sizeof(__pyx_k_gids), 0, 0, 1, 1}, {&__pyx_kp_u_handler_raised_s_exception_s_ter, __pyx_k_handler_raised_s_exception_s_ter, sizeof(__pyx_k_handler_raised_s_exception_s_ter), 0, 1, 0, 0}, {&__pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_k_home_nikratio_in_progress_pytho, sizeof(__pyx_k_home_nikratio_in_progress_pytho), 0, 0, 1, 0}, {&__pyx_kp_s_home_nikratio_in_progress_pytho_2, __pyx_k_home_nikratio_in_progress_pytho_2, sizeof(__pyx_k_home_nikratio_in_progress_pytho_2), 0, 0, 1, 0}, {&__pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_k_home_nikratio_in_progress_pytho_3, sizeof(__pyx_k_home_nikratio_in_progress_pytho_3), 0, 0, 1, 0}, {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1}, {&__pyx_n_s_info, __pyx_k_info, sizeof(__pyx_k_info), 0, 0, 1, 1}, {&__pyx_n_s_init, __pyx_k_init, sizeof(__pyx_k_init), 0, 0, 1, 1}, {&__pyx_n_s_ino, __pyx_k_ino, sizeof(__pyx_k_ino), 0, 0, 1, 1}, {&__pyx_n_s_inode, __pyx_k_inode, sizeof(__pyx_k_inode), 0, 0, 1, 1}, {&__pyx_n_s_inode_list, __pyx_k_inode_list, sizeof(__pyx_k_inode_list), 0, 0, 1, 1}, {&__pyx_n_s_inode_p, __pyx_k_inode_p, sizeof(__pyx_k_inode_p), 0, 0, 1, 1}, {&__pyx_n_s_invalidate_entry, __pyx_k_invalidate_entry, sizeof(__pyx_k_invalidate_entry), 0, 0, 1, 1}, {&__pyx_n_s_invalidate_inode, __pyx_k_invalidate_inode, sizeof(__pyx_k_invalidate_inode), 0, 0, 1, 1}, {&__pyx_n_s_items, __pyx_k_items, sizeof(__pyx_k_items), 0, 0, 1, 1}, {&__pyx_n_s_join, __pyx_k_join, sizeof(__pyx_k_join), 0, 0, 1, 1}, {&__pyx_n_s_len, __pyx_k_len, sizeof(__pyx_k_len), 0, 0, 1, 1}, {&__pyx_n_s_line, __pyx_k_line, sizeof(__pyx_k_line), 0, 0, 1, 1}, {&__pyx_n_s_lineno, __pyx_k_lineno, sizeof(__pyx_k_lineno), 0, 0, 1, 1}, {&__pyx_n_s_link, __pyx_k_link, sizeof(__pyx_k_link), 0, 0, 1, 1}, {&__pyx_n_s_listdir, __pyx_k_listdir, sizeof(__pyx_k_listdir), 0, 0, 1, 1}, {&__pyx_n_s_listxattr, __pyx_k_listxattr, sizeof(__pyx_k_listxattr), 0, 0, 1, 1}, {&__pyx_n_s_llfuse, __pyx_k_llfuse, sizeof(__pyx_k_llfuse), 0, 0, 1, 1}, {&__pyx_n_u_llfuse, __pyx_k_llfuse, sizeof(__pyx_k_llfuse), 0, 1, 0, 1}, {&__pyx_n_s_lock, __pyx_k_lock, sizeof(__pyx_k_lock), 0, 0, 1, 1}, {&__pyx_n_s_lock_released, __pyx_k_lock_released, sizeof(__pyx_k_lock_released), 0, 0, 1, 1}, {&__pyx_n_s_log, __pyx_k_log, sizeof(__pyx_k_log), 0, 0, 1, 1}, {&__pyx_n_s_logging, __pyx_k_logging, sizeof(__pyx_k_logging), 0, 0, 1, 1}, {&__pyx_n_s_lookup, __pyx_k_lookup, sizeof(__pyx_k_lookup), 0, 0, 1, 1}, {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1}, {&__pyx_n_s_main_2, __pyx_k_main_2, sizeof(__pyx_k_main_2), 0, 0, 1, 1}, {&__pyx_n_s_main_locals_lambda, __pyx_k_main_locals_lambda, sizeof(__pyx_k_main_locals_lambda), 0, 0, 1, 1}, {&__pyx_n_s_maxsize, __pyx_k_maxsize, sizeof(__pyx_k_maxsize), 0, 0, 1, 1}, {&__pyx_n_s_metaclass, __pyx_k_metaclass, sizeof(__pyx_k_metaclass), 0, 0, 1, 1}, {&__pyx_n_s_mkdir, __pyx_k_mkdir, sizeof(__pyx_k_mkdir), 0, 0, 1, 1}, {&__pyx_n_s_mknod, __pyx_k_mknod, sizeof(__pyx_k_mknod), 0, 0, 1, 1}, {&__pyx_n_s_mode, __pyx_k_mode, sizeof(__pyx_k_mode), 0, 0, 1, 1}, {&__pyx_n_s_module, __pyx_k_module, sizeof(__pyx_k_module), 0, 0, 1, 1}, {&__pyx_n_s_mountpoint, __pyx_k_mountpoint, sizeof(__pyx_k_mountpoint), 0, 0, 1, 1}, {&__pyx_kp_u_mountpoint__argument_must_be_of, __pyx_k_mountpoint__argument_must_be_of, sizeof(__pyx_k_mountpoint__argument_must_be_of), 0, 1, 0, 0}, {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1}, {&__pyx_kp_u_name_argument_must_be_of_type_s, __pyx_k_name_argument_must_be_of_type_s, sizeof(__pyx_k_name_argument_must_be_of_type_s), 0, 1, 0, 0}, {&__pyx_n_s_name_b, __pyx_k_name_b, sizeof(__pyx_k_name_b), 0, 0, 1, 1}, {&__pyx_n_s_name_new, __pyx_k_name_new, sizeof(__pyx_k_name_new), 0, 0, 1, 1}, {&__pyx_n_s_name_old, __pyx_k_name_old, sizeof(__pyx_k_name_old), 0, 0, 1, 1}, {&__pyx_n_s_names, __pyx_k_names, sizeof(__pyx_k_names), 0, 0, 1, 1}, {&__pyx_n_s_namespace, __pyx_k_namespace, sizeof(__pyx_k_namespace), 0, 0, 1, 1}, {&__pyx_kp_u_namespace_parameter_must_be_sys, __pyx_k_namespace_parameter_must_be_sys, sizeof(__pyx_k_namespace_parameter_must_be_sys), 0, 1, 0, 0}, {&__pyx_n_s_new_name, __pyx_k_new_name, sizeof(__pyx_k_new_name), 0, 0, 1, 1}, {&__pyx_n_s_new_parent_inode, __pyx_k_new_parent_inode, sizeof(__pyx_k_new_parent_inode), 0, 0, 1, 1}, {&__pyx_n_u_no_splice_read, __pyx_k_no_splice_read, sizeof(__pyx_k_no_splice_read), 0, 1, 0, 1}, {&__pyx_n_u_nonempty, __pyx_k_nonempty, sizeof(__pyx_k_nonempty), 0, 1, 0, 1}, {&__pyx_n_s_notify_loop, __pyx_k_notify_loop, sizeof(__pyx_k_notify_loop), 0, 0, 1, 1}, {&__pyx_n_s_notify_store, __pyx_k_notify_store, sizeof(__pyx_k_notify_store), 0, 0, 1, 1}, {&__pyx_kp_b_o, __pyx_k_o, sizeof(__pyx_k_o), 0, 0, 0, 0}, {&__pyx_n_s_object, __pyx_k_object, sizeof(__pyx_k_object), 0, 0, 1, 1}, {&__pyx_n_s_off, __pyx_k_off, sizeof(__pyx_k_off), 0, 0, 1, 1}, {&__pyx_n_s_offset, __pyx_k_offset, sizeof(__pyx_k_offset), 0, 0, 1, 1}, {&__pyx_n_s_on_exit, __pyx_k_on_exit, sizeof(__pyx_k_on_exit), 0, 0, 1, 1}, {&__pyx_n_s_open, __pyx_k_open, sizeof(__pyx_k_open), 0, 0, 1, 1}, {&__pyx_n_s_opendir, __pyx_k_opendir, sizeof(__pyx_k_opendir), 0, 0, 1, 1}, {&__pyx_n_s_ops, __pyx_k_ops, sizeof(__pyx_k_ops), 0, 0, 1, 1}, {&__pyx_n_s_options, __pyx_k_options, sizeof(__pyx_k_options), 0, 0, 1, 1}, {&__pyx_n_s_os, __pyx_k_os, sizeof(__pyx_k_os), 0, 0, 1, 1}, {&__pyx_n_s_os_path, __pyx_k_os_path, sizeof(__pyx_k_os_path), 0, 0, 1, 1}, {&__pyx_n_s_parent_inode, __pyx_k_parent_inode, sizeof(__pyx_k_parent_inode), 0, 0, 1, 1}, {&__pyx_n_s_parent_inode_new, __pyx_k_parent_inode_new, sizeof(__pyx_k_parent_inode_new), 0, 0, 1, 1}, {&__pyx_n_s_parent_inode_old, __pyx_k_parent_inode_old, sizeof(__pyx_k_parent_inode_old), 0, 0, 1, 1}, {&__pyx_n_s_path, __pyx_k_path, sizeof(__pyx_k_path), 0, 0, 1, 1}, {&__pyx_kp_u_path_argument_must_be_of_type_s, __pyx_k_path_argument_must_be_of_type_s, sizeof(__pyx_k_path_argument_must_be_of_type_s), 0, 1, 0, 0}, {&__pyx_n_s_path_b, __pyx_k_path_b, sizeof(__pyx_k_path_b), 0, 0, 1, 1}, {&__pyx_n_s_pickle, __pyx_k_pickle, sizeof(__pyx_k_pickle), 0, 0, 1, 1}, {&__pyx_n_s_pid, __pyx_k_pid, sizeof(__pyx_k_pid), 0, 0, 1, 1}, {&__pyx_n_s_prepare, __pyx_k_prepare, sizeof(__pyx_k_prepare), 0, 0, 1, 1}, {&__pyx_kp_u_proc_d_status, __pyx_k_proc_d_status, sizeof(__pyx_k_proc_d_status), 0, 1, 0, 0}, {&__pyx_kp_u_pthread_create_failed_with, __pyx_k_pthread_create_failed_with, sizeof(__pyx_k_pthread_create_failed_with), 0, 1, 0, 0}, {&__pyx_kp_u_pthread_join_failed_with_s, __pyx_k_pthread_join_failed_with_s, sizeof(__pyx_k_pthread_join_failed_with_s), 0, 1, 0, 0}, {&__pyx_kp_u_pthread_kill_failed_with_s, __pyx_k_pthread_kill_failed_with_s, sizeof(__pyx_k_pthread_kill_failed_with_s), 0, 1, 0, 0}, {&__pyx_kp_u_pthread_mutex_lock_failed_with_s, __pyx_k_pthread_mutex_lock_failed_with_s, sizeof(__pyx_k_pthread_mutex_lock_failed_with_s), 0, 1, 0, 0}, {&__pyx_kp_u_pthread_mutex_ulock_failed_with, __pyx_k_pthread_mutex_ulock_failed_with, sizeof(__pyx_k_pthread_mutex_ulock_failed_with), 0, 1, 0, 0}, {&__pyx_n_s_put, __pyx_k_put, sizeof(__pyx_k_put), 0, 0, 1, 1}, {&__pyx_n_s_pybuf, __pyx_k_pybuf, sizeof(__pyx_k_pybuf), 0, 0, 1, 1}, {&__pyx_n_s_qualname, __pyx_k_qualname, sizeof(__pyx_k_qualname), 0, 0, 1, 1}, {&__pyx_n_s_queue, __pyx_k_queue, sizeof(__pyx_k_queue), 0, 0, 1, 1}, {&__pyx_n_u_r, __pyx_k_r, sizeof(__pyx_k_r), 0, 1, 0, 1}, {&__pyx_n_s_range, __pyx_k_range, sizeof(__pyx_k_range), 0, 0, 1, 1}, {&__pyx_n_s_rdev, __pyx_k_rdev, sizeof(__pyx_k_rdev), 0, 0, 1, 1}, {&__pyx_n_s_read, __pyx_k_read, sizeof(__pyx_k_read), 0, 0, 1, 1}, {&__pyx_n_s_readdir, __pyx_k_readdir, sizeof(__pyx_k_readdir), 0, 0, 1, 1}, {&__pyx_n_s_readlink, __pyx_k_readlink, sizeof(__pyx_k_readlink), 0, 0, 1, 1}, {&__pyx_n_s_release, __pyx_k_release, sizeof(__pyx_k_release), 0, 0, 1, 1}, {&__pyx_n_s_releasedir, __pyx_k_releasedir, sizeof(__pyx_k_releasedir), 0, 0, 1, 1}, {&__pyx_n_s_removexattr, __pyx_k_removexattr, sizeof(__pyx_k_removexattr), 0, 0, 1, 1}, {&__pyx_n_s_rename, __pyx_k_rename, sizeof(__pyx_k_rename), 0, 0, 1, 1}, {&__pyx_n_s_req, __pyx_k_req, sizeof(__pyx_k_req), 0, 0, 1, 1}, {&__pyx_n_s_res, __pyx_k_res, sizeof(__pyx_k_res), 0, 0, 1, 1}, {&__pyx_n_s_ret, __pyx_k_ret, sizeof(__pyx_k_ret), 0, 0, 1, 1}, {&__pyx_n_s_rmdir, __pyx_k_rmdir, sizeof(__pyx_k_rmdir), 0, 0, 1, 1}, {&__pyx_kp_u_s, __pyx_k_s, sizeof(__pyx_k_s), 0, 1, 0, 0}, {&__pyx_kp_u_s_d_in_s, __pyx_k_s_d_in_s, sizeof(__pyx_k_s_d_in_s), 0, 1, 0, 0}, {&__pyx_n_s_self, __pyx_k_self, sizeof(__pyx_k_self), 0, 0, 1, 1}, {&__pyx_kp_u_sem_init_failed_with, __pyx_k_sem_init_failed_with, sizeof(__pyx_k_sem_init_failed_with), 0, 1, 0, 0}, {&__pyx_n_s_setattr, __pyx_k_setattr, sizeof(__pyx_k_setattr), 0, 0, 1, 1}, {&__pyx_n_s_setxattr, __pyx_k_setxattr, sizeof(__pyx_k_setxattr), 0, 0, 1, 1}, {&__pyx_kp_u_sigaction_failed_with, __pyx_k_sigaction_failed_with, sizeof(__pyx_k_sigaction_failed_with), 0, 1, 0, 0}, {&__pyx_n_s_size, __pyx_k_size, sizeof(__pyx_k_size), 0, 0, 1, 1}, {&__pyx_n_s_size_guess, __pyx_k_size_guess, sizeof(__pyx_k_size_guess), 0, 0, 1, 1}, {&__pyx_n_u_splice_move, __pyx_k_splice_move, sizeof(__pyx_k_splice_move), 0, 1, 0, 1}, {&__pyx_n_u_splice_write, __pyx_k_splice_write, sizeof(__pyx_k_splice_write), 0, 1, 0, 1}, {&__pyx_n_s_split, __pyx_k_split, sizeof(__pyx_k_split), 0, 0, 1, 1}, {&__pyx_n_u_st_atime_ns, __pyx_k_st_atime_ns, sizeof(__pyx_k_st_atime_ns), 0, 1, 0, 1}, {&__pyx_n_u_st_birthtime_ns, __pyx_k_st_birthtime_ns, sizeof(__pyx_k_st_birthtime_ns), 0, 1, 0, 1}, {&__pyx_n_u_st_blksize, __pyx_k_st_blksize, sizeof(__pyx_k_st_blksize), 0, 1, 0, 1}, {&__pyx_n_u_st_blocks, __pyx_k_st_blocks, sizeof(__pyx_k_st_blocks), 0, 1, 0, 1}, {&__pyx_n_u_st_ctime_ns, __pyx_k_st_ctime_ns, sizeof(__pyx_k_st_ctime_ns), 0, 1, 0, 1}, {&__pyx_n_u_st_gid, __pyx_k_st_gid, sizeof(__pyx_k_st_gid), 0, 1, 0, 1}, {&__pyx_n_u_st_ino, __pyx_k_st_ino, sizeof(__pyx_k_st_ino), 0, 1, 0, 1}, {&__pyx_n_u_st_mode, __pyx_k_st_mode, sizeof(__pyx_k_st_mode), 0, 1, 0, 1}, {&__pyx_n_u_st_mtime_ns, __pyx_k_st_mtime_ns, sizeof(__pyx_k_st_mtime_ns), 0, 1, 0, 1}, {&__pyx_n_u_st_nlink, __pyx_k_st_nlink, sizeof(__pyx_k_st_nlink), 0, 1, 0, 1}, {&__pyx_n_u_st_rdev, __pyx_k_st_rdev, sizeof(__pyx_k_st_rdev), 0, 1, 0, 1}, {&__pyx_n_u_st_size, __pyx_k_st_size, sizeof(__pyx_k_st_size), 0, 1, 0, 1}, {&__pyx_n_u_st_uid, __pyx_k_st_uid, sizeof(__pyx_k_st_uid), 0, 1, 0, 1}, {&__pyx_n_s_stacktrace, __pyx_k_stacktrace, sizeof(__pyx_k_stacktrace), 0, 0, 1, 1}, {&__pyx_n_s_start, __pyx_k_start, sizeof(__pyx_k_start), 0, 0, 1, 1}, {&__pyx_n_s_startswith, __pyx_k_startswith, sizeof(__pyx_k_startswith), 0, 0, 1, 1}, {&__pyx_n_s_statfs, __pyx_k_statfs, sizeof(__pyx_k_statfs), 0, 0, 1, 1}, {&__pyx_n_s_str_t, __pyx_k_str_t, sizeof(__pyx_k_str_t), 0, 0, 1, 1}, {&__pyx_n_s_strerror, __pyx_k_strerror, sizeof(__pyx_k_strerror), 0, 0, 1, 1}, {&__pyx_n_s_strip, __pyx_k_strip, sizeof(__pyx_k_strip), 0, 0, 1, 1}, {&__pyx_n_u_surrogateescape, __pyx_k_surrogateescape, sizeof(__pyx_k_surrogateescape), 0, 1, 0, 1}, {&__pyx_n_s_symlink, __pyx_k_symlink, sizeof(__pyx_k_symlink), 0, 0, 1, 1}, {&__pyx_n_s_sys, __pyx_k_sys, sizeof(__pyx_k_sys), 0, 0, 1, 1}, {&__pyx_n_u_system, __pyx_k_system, sizeof(__pyx_k_system), 0, 1, 0, 1}, {&__pyx_n_s_t, __pyx_k_t, sizeof(__pyx_k_t), 0, 0, 1, 1}, {&__pyx_n_s_target, __pyx_k_target, sizeof(__pyx_k_target), 0, 0, 1, 1}, {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1}, {&__pyx_n_s_threadId, __pyx_k_threadId, sizeof(__pyx_k_threadId), 0, 0, 1, 1}, {&__pyx_n_s_threading, __pyx_k_threading, sizeof(__pyx_k_threading), 0, 0, 1, 1}, {&__pyx_n_s_timeout, __pyx_k_timeout, sizeof(__pyx_k_timeout), 0, 0, 1, 1}, {&__pyx_n_s_tmp, __pyx_k_tmp, sizeof(__pyx_k_tmp), 0, 0, 1, 1}, {&__pyx_n_s_traceback, __pyx_k_traceback, sizeof(__pyx_k_traceback), 0, 0, 1, 1}, {&__pyx_n_s_uname, __pyx_k_uname, sizeof(__pyx_k_uname), 0, 0, 1, 1}, {&__pyx_kp_u_unknown_flag_s_o, __pyx_k_unknown_flag_s_o, sizeof(__pyx_k_unknown_flag_s_o), 0, 1, 0, 0}, {&__pyx_n_s_unlink, __pyx_k_unlink, sizeof(__pyx_k_unlink), 0, 0, 1, 1}, {&__pyx_n_s_unmount, __pyx_k_unmount, sizeof(__pyx_k_unmount), 0, 0, 1, 1}, {&__pyx_kp_u_us_ascii, __pyx_k_us_ascii, sizeof(__pyx_k_us_ascii), 0, 1, 0, 0}, {&__pyx_n_u_user, __pyx_k_user, sizeof(__pyx_k_user), 0, 1, 0, 1}, {&__pyx_n_s_value, __pyx_k_value, sizeof(__pyx_k_value), 0, 0, 1, 1}, {&__pyx_n_s_version, __pyx_k_version, sizeof(__pyx_k_version), 0, 0, 1, 1}, {&__pyx_n_s_with_traceback, __pyx_k_with_traceback, sizeof(__pyx_k_with_traceback), 0, 0, 1, 1}, {&__pyx_n_s_workers, __pyx_k_workers, sizeof(__pyx_k_workers), 0, 0, 1, 1}, {&__pyx_n_s_write, __pyx_k_write, sizeof(__pyx_k_write), 0, 0, 1, 1}, {&__pyx_n_s_x, __pyx_k_x, sizeof(__pyx_k_x), 0, 0, 1, 1}, {0, 0, 0, 0, 0, 0, 0} }; static int __Pyx_InitCachedBuiltins(void) { __pyx_builtin_object = __Pyx_GetBuiltinName(__pyx_n_s_object); if (!__pyx_builtin_object) __PYX_ERR(0, 11, __pyx_L1_error) __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range); if (!__pyx_builtin_range) __PYX_ERR(1, 65, __pyx_L1_error) __pyx_builtin_OverflowError = __Pyx_GetBuiltinName(__pyx_n_s_OverflowError); if (!__pyx_builtin_OverflowError) __PYX_ERR(1, 344, __pyx_L1_error) __pyx_builtin_ValueError = __Pyx_GetBuiltinName(__pyx_n_s_ValueError); if (!__pyx_builtin_ValueError) __PYX_ERR(1, 575, __pyx_L1_error) __pyx_builtin_enumerate = __Pyx_GetBuiltinName(__pyx_n_s_enumerate); if (!__pyx_builtin_enumerate) __PYX_ERR(2, 122, __pyx_L1_error) __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(2, 146, __pyx_L1_error) __pyx_builtin_RuntimeError = __Pyx_GetBuiltinName(__pyx_n_s_RuntimeError); if (!__pyx_builtin_RuntimeError) __PYX_ERR(2, 173, __pyx_L1_error) __pyx_builtin_OSError = __Pyx_GetBuiltinName(__pyx_n_s_OSError); if (!__pyx_builtin_OSError) __PYX_ERR(2, 676, __pyx_L1_error) __pyx_builtin_MemoryError = __Pyx_GetBuiltinName(__pyx_n_s_MemoryError); if (!__pyx_builtin_MemoryError) __PYX_ERR(2, 746, __pyx_L1_error) __pyx_builtin_open = __Pyx_GetBuiltinName(__pyx_n_s_open); if (!__pyx_builtin_open) __PYX_ERR(3, 638, __pyx_L1_error) return 0; __pyx_L1_error:; return -1; } static int __Pyx_InitCachedConstants(void) { __Pyx_RefNannyDeclarations __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0); /* "src/handlers.pxi":15 * cdef void fuse_init (void *userdata, fuse_conn_info *conn) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.init() * except: */ __pyx_tuple__2 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(1, 15, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__2); __Pyx_GIVEREF(__pyx_tuple__2); /* "src/handlers.pxi":23 * global exc_info * try: * with lock: # <<<<<<<<<<<<<< * operations.destroy() * except: */ __pyx_tuple__3 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__3)) __PYX_ERR(1, 23, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__3); __Pyx_GIVEREF(__pyx_tuple__3); /* "src/handlers.pxi":29 * exc_info = sys.exc_info() * else: * log.exception('Exception after kill:') # <<<<<<<<<<<<<< * * cdef void fuse_lookup (fuse_req_t req, fuse_ino_t parent, */ __pyx_tuple__4 = PyTuple_Pack(1, __pyx_kp_u_Exception_after_kill); if (unlikely(!__pyx_tuple__4)) __PYX_ERR(1, 29, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__4); __Pyx_GIVEREF(__pyx_tuple__4); /* "src/handlers.pxi":39 * ctx = get_request_context(req) * name = PyBytes_FromString(c_name) * with lock: # <<<<<<<<<<<<<< * entry = operations.lookup(parent, name, ctx) * ret = fuse_reply_entry(req, &entry.fuse_param) */ __pyx_tuple__5 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(1, 39, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__5); __Pyx_GIVEREF(__pyx_tuple__5); /* "src/handlers.pxi":54 * ulong_t nlookup) with gil: * try: * with lock: # <<<<<<<<<<<<<< * operations.forget([(ino, nlookup)]) * except: */ __pyx_tuple__6 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__6)) __PYX_ERR(1, 54, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__6); __Pyx_GIVEREF(__pyx_tuple__6); /* "src/handlers.pxi":67 * for i in range(0, count): * forget_list.append((forgets[i].ino, forgets[i].nlookup)) * with lock: # <<<<<<<<<<<<<< * operations.forget(forget_list) * except: */ __pyx_tuple__7 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__7)) __PYX_ERR(1, 67, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__7); __Pyx_GIVEREF(__pyx_tuple__7); /* "src/handlers.pxi":80 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.getattr(ino, ctx) * */ __pyx_tuple__8 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__8)) __PYX_ERR(1, 80, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__8); __Pyx_GIVEREF(__pyx_tuple__8); /* "src/handlers.pxi":136 * else: * fh = fi.fh * with lock: # <<<<<<<<<<<<<< * entry = operations.setattr(ino, entry, fields, fh, ctx) * */ __pyx_tuple__9 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__9)) __PYX_ERR(1, 136, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__9); __Pyx_GIVEREF(__pyx_tuple__9); /* "src/handlers.pxi":153 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * target = operations.readlink(ino, ctx) * name = PyBytes_AsString(target) */ __pyx_tuple__10 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__10)) __PYX_ERR(1, 153, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__10); __Pyx_GIVEREF(__pyx_tuple__10); /* "src/handlers.pxi":172 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mknod(parent, PyBytes_FromString(name), * mode, rdev, ctx) */ __pyx_tuple__11 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(1, 172, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__11); __Pyx_GIVEREF(__pyx_tuple__11); /* "src/handlers.pxi":194 * mode = (mode & ~ S_IFMT) | S_IFDIR * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.mkdir(parent, PyBytes_FromString(name), * mode, ctx) */ __pyx_tuple__12 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(1, 194, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__12); __Pyx_GIVEREF(__pyx_tuple__12); /* "src/handlers.pxi":211 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.unlink(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__13 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__13)) __PYX_ERR(1, 211, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__13); __Pyx_GIVEREF(__pyx_tuple__13); /* "src/handlers.pxi":227 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rmdir(parent, PyBytes_FromString(name), ctx) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__14 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(1, 227, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__14); __Pyx_GIVEREF(__pyx_tuple__14); /* "src/handlers.pxi":245 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.symlink(parent, PyBytes_FromString(name), * PyBytes_FromString(link), ctx) */ __pyx_tuple__15 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(1, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__15); __Pyx_GIVEREF(__pyx_tuple__15); /* "src/handlers.pxi":263 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * operations.rename(parent, PyBytes_FromString(name), * newparent, PyBytes_FromString(newname), ctx) */ __pyx_tuple__16 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(1, 263, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__16); __Pyx_GIVEREF(__pyx_tuple__16); /* "src/handlers.pxi":282 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * entry = operations.link(ino, newparent, * PyBytes_FromString(newname), ctx) */ __pyx_tuple__17 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(1, 282, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__17); __Pyx_GIVEREF(__pyx_tuple__17); /* "src/handlers.pxi":300 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.open(ino, fi.flags, ctx) * */ __pyx_tuple__18 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(1, 300, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__18); __Pyx_GIVEREF(__pyx_tuple__18); /* "src/handlers.pxi":322 * * try: * with lock: # <<<<<<<<<<<<<< * buf = operations.read(fi.fh, off, size) * */ __pyx_tuple__19 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__19)) __PYX_ERR(1, 322, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__19); __Pyx_GIVEREF(__pyx_tuple__19); /* "src/handlers.pxi":344 * try: * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * pbuf = PyBytes_FromStringAndSize(buf, size) * */ __pyx_tuple__20 = PyTuple_Pack(1, __pyx_kp_u_Value_too_long_to_convert_to_Pyt); if (unlikely(!__pyx_tuple__20)) __PYX_ERR(1, 344, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__20); __Pyx_GIVEREF(__pyx_tuple__20); /* "src/handlers.pxi":351 * # not initialized. * len_ = 0 * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, pbuf) * ret = fuse_reply_write(req, len_) */ __pyx_tuple__21 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__21)) __PYX_ERR(1, 351, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__21); __Pyx_GIVEREF(__pyx_tuple__21); /* "src/handlers.pxi":374 * * buf = PyBytes_from_bufvec(bufv) * with lock: # <<<<<<<<<<<<<< * len_ = operations.write(fi.fh, off, buf) * ret = fuse_reply_write(req, len_) */ __pyx_tuple__22 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__22)) __PYX_ERR(1, 374, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__22); __Pyx_GIVEREF(__pyx_tuple__22); /* "src/handlers.pxi":389 * * try: * with lock: # <<<<<<<<<<<<<< * operations.flush(fi.fh) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__23 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(1, 389, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__23); __Pyx_GIVEREF(__pyx_tuple__23); /* "src/handlers.pxi":404 * * try: * with lock: # <<<<<<<<<<<<<< * operations.release(fi.fh) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__24 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__24)) __PYX_ERR(1, 404, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__24); __Pyx_GIVEREF(__pyx_tuple__24); /* "src/handlers.pxi":420 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsync(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__25 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(1, 420, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__25); __Pyx_GIVEREF(__pyx_tuple__25); /* "src/handlers.pxi":436 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * fi.fh = operations.opendir(ino, ctx) * */ __pyx_tuple__26 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__26)) __PYX_ERR(1, 436, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__26); __Pyx_GIVEREF(__pyx_tuple__26); /* "src/handlers.pxi":459 * acc_size = 0 * buf = NULL * with lock: # <<<<<<<<<<<<<< * for (name, attr, next_) in operations.readdir(fi.fh, off): * entry = attr */ __pyx_tuple__27 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(1, 459, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__27); __Pyx_GIVEREF(__pyx_tuple__27); /* "src/handlers.pxi":486 * * try: * with lock: # <<<<<<<<<<<<<< * operations.releasedir(fi.fh) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__28 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__28)) __PYX_ERR(1, 486, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__28); __Pyx_GIVEREF(__pyx_tuple__28); /* "src/handlers.pxi":503 * * try: * with lock: # <<<<<<<<<<<<<< * operations.fsyncdir(fi.fh, datasync != 0) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__29 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(1, 503, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__29); __Pyx_GIVEREF(__pyx_tuple__29); /* "src/handlers.pxi":522 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * stats = operations.statfs(ctx) * ret = fuse_reply_statfs(req, &stats.stat) */ __pyx_tuple__30 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__30)) __PYX_ERR(1, 522, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__30); __Pyx_GIVEREF(__pyx_tuple__30); /* "src/handlers.pxi":561 * name = PyBytes_FromString(cname) * if size > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * value = PyBytes_FromStringAndSize(cvalue, size) * */ __pyx_tuple__31 = PyTuple_Pack(1, __pyx_kp_u_Value_too_long_to_convert_to_Pyt); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(1, 561, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__31); __Pyx_GIVEREF(__pyx_tuple__31); /* "src/handlers.pxi":570 * if PLATFORM == PLATFORM_DARWIN: * # No known flags * with lock: # <<<<<<<<<<<<<< * operations.setxattr(ino, name, value, ctx) * else: */ __pyx_tuple__32 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__32)) __PYX_ERR(1, 570, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__32); __Pyx_GIVEREF(__pyx_tuple__32); /* "src/handlers.pxi":577 * raise ValueError('unknown flag(s): %o' % flags) * * with lock: # <<<<<<<<<<<<<< * if flags & XATTR_CREATE: # Attribute must not exist * try: */ __pyx_tuple__33 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(1, 577, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__33); __Pyx_GIVEREF(__pyx_tuple__33); /* "src/handlers.pxi":622 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * buf = operations.getxattr(ino, name, ctx) * PyBytes_AsStringAndSize(buf, &cbuf, &len_s) */ __pyx_tuple__34 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__34)) __PYX_ERR(1, 622, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__34); __Pyx_GIVEREF(__pyx_tuple__34); /* "src/handlers.pxi":648 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * buf = b'\0'.join(operations.listxattr(ino, ctx)) + b'\0' * */ __pyx_tuple__36 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__36)) __PYX_ERR(1, 648, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__36); __Pyx_GIVEREF(__pyx_tuple__36); /* "src/handlers.pxi":676 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * operations.removexattr(ino, name, ctx) * ret = fuse_reply_err(req, 0) */ __pyx_tuple__37 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__37)) __PYX_ERR(1, 676, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__37); __Pyx_GIVEREF(__pyx_tuple__37); /* "src/handlers.pxi":692 * try: * ctx = get_request_context(req) * with lock: # <<<<<<<<<<<<<< * allowed = operations.access(ino, mask, ctx) * if allowed: */ __pyx_tuple__38 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__38)) __PYX_ERR(1, 692, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__38); __Pyx_GIVEREF(__pyx_tuple__38); /* "src/handlers.pxi":715 * ctx = get_request_context(req) * name = PyBytes_FromString(cname) * with lock: # <<<<<<<<<<<<<< * tmp = operations.create(parent, name, mode, fi.flags, ctx) * fi.fh = tmp[0] */ __pyx_tuple__39 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__39)) __PYX_ERR(1, 715, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__39); __Pyx_GIVEREF(__pyx_tuple__39); /* "src/misc.pxi":29 * fuse_session_exit(session) * else: * log.exception('Only one exception can be re-raised in `llfuse.main`, ' # <<<<<<<<<<<<<< * 'the following exception will be lost') * */ __pyx_tuple__40 = PyTuple_Pack(1, __pyx_kp_u_Only_one_exception_can_be_re_rai); if (unlikely(!__pyx_tuple__40)) __PYX_ERR(2, 29, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__40); __Pyx_GIVEREF(__pyx_tuple__40); /* "src/misc.pxi":107 * for el in args: * args_new.append(b'-o') * args_new.append(el.encode('us-ascii')) # <<<<<<<<<<<<<< * args = args_new * */ __pyx_tuple__41 = PyTuple_Pack(1, __pyx_kp_u_us_ascii); if (unlikely(!__pyx_tuple__41)) __PYX_ERR(2, 107, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__41); __Pyx_GIVEREF(__pyx_tuple__41); /* "src/misc.pxi":146 * * def __init__(self): * raise TypeError('You should not instantiate this class, use the ' # <<<<<<<<<<<<<< * 'provided instance instead.') * */ __pyx_tuple__42 = PyTuple_Pack(1, __pyx_kp_u_You_should_not_instantiate_this); if (unlikely(!__pyx_tuple__42)) __PYX_ERR(2, 146, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__42); __Pyx_GIVEREF(__pyx_tuple__42); /* "src/misc.pxi":173 * return False * elif ret == EDEADLK: * raise RuntimeError("Global lock cannot be acquired more than once") # <<<<<<<<<<<<<< * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") */ __pyx_tuple__43 = PyTuple_Pack(1, __pyx_kp_u_Global_lock_cannot_be_acquired_m); if (unlikely(!__pyx_tuple__43)) __PYX_ERR(2, 173, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__43); __Pyx_GIVEREF(__pyx_tuple__43); /* "src/misc.pxi":175 * raise RuntimeError("Global lock cannot be acquired more than once") * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_tuple__44 = PyTuple_Pack(1, __pyx_kp_u_Lock_still_taken_after_receiving); if (unlikely(!__pyx_tuple__44)) __PYX_ERR(2, 175, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__44); __Pyx_GIVEREF(__pyx_tuple__44); /* "src/misc.pxi":177 * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_tuple__45 = PyTuple_Pack(1, __pyx_kp_u_Lock_not_initialized); if (unlikely(!__pyx_tuple__45)) __PYX_ERR(2, 177, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__45); __Pyx_GIVEREF(__pyx_tuple__45); /* "src/misc.pxi":191 * return * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_tuple__46 = PyTuple_Pack(1, __pyx_kp_u_Lock_can_only_be_released_by_the); if (unlikely(!__pyx_tuple__46)) __PYX_ERR(2, 191, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__46); __Pyx_GIVEREF(__pyx_tuple__46); /* "src/misc.pxi":193 * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_tuple__47 = PyTuple_Pack(1, __pyx_kp_u_Lock_not_initialized); if (unlikely(!__pyx_tuple__47)) __PYX_ERR(2, 193, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__47); __Pyx_GIVEREF(__pyx_tuple__47); /* "src/misc.pxi":223 * return * elif ret == EPERM: * raise RuntimeError("Lock can only be released by the holding thread") # <<<<<<<<<<<<<< * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") */ __pyx_tuple__48 = PyTuple_Pack(1, __pyx_kp_u_Lock_can_only_be_released_by_the); if (unlikely(!__pyx_tuple__48)) __PYX_ERR(2, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__48); __Pyx_GIVEREF(__pyx_tuple__48); /* "src/misc.pxi":225 * raise RuntimeError("Lock can only be released by the holding thread") * elif ret == EPROTO: * raise RuntimeError("Lock still taken after receiving unlock notification") # <<<<<<<<<<<<<< * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") */ __pyx_tuple__49 = PyTuple_Pack(1, __pyx_kp_u_Lock_still_taken_after_receiving); if (unlikely(!__pyx_tuple__49)) __PYX_ERR(2, 225, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__49); __Pyx_GIVEREF(__pyx_tuple__49); /* "src/misc.pxi":227 * raise RuntimeError("Lock still taken after receiving unlock notification") * elif ret == ENOMSG: * raise RuntimeError("Other thread didn't take lock") # <<<<<<<<<<<<<< * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") */ __pyx_tuple__50 = PyTuple_Pack(1, __pyx_kp_u_Other_thread_didn_t_take_lock); if (unlikely(!__pyx_tuple__50)) __PYX_ERR(2, 227, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__50); __Pyx_GIVEREF(__pyx_tuple__50); /* "src/misc.pxi":229 * raise RuntimeError("Other thread didn't take lock") * elif ret == EINVAL: * raise RuntimeError("Lock not initialized") # <<<<<<<<<<<<<< * else: * raise RuntimeError(strerror(ret)) */ __pyx_tuple__51 = PyTuple_Pack(1, __pyx_kp_u_Lock_not_initialized); if (unlikely(!__pyx_tuple__51)) __PYX_ERR(2, 229, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__51); __Pyx_GIVEREF(__pyx_tuple__51); /* "src/misc.pxi":240 * * def __getstate__(self): * raise PicklingError("Lock instances can't be pickled") # <<<<<<<<<<<<<< * * cdef class NoLockManager: */ __pyx_tuple__52 = PyTuple_Pack(1, __pyx_kp_u_Lock_instances_can_t_be_pickled); if (unlikely(!__pyx_tuple__52)) __PYX_ERR(2, 240, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__52); __Pyx_GIVEREF(__pyx_tuple__52); /* "src/misc.pxi":246 * * def __init__(self): * raise TypeError('You should not instantiate this class, use the ' # <<<<<<<<<<<<<< * 'provided instance instead.') * */ __pyx_tuple__53 = PyTuple_Pack(1, __pyx_kp_u_You_should_not_instantiate_this); if (unlikely(!__pyx_tuple__53)) __PYX_ERR(2, 246, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__53); __Pyx_GIVEREF(__pyx_tuple__53); /* "src/misc.pxi":256 * * def __getstate__(self): * raise PicklingError("NoLockManager instances can't be pickled") # <<<<<<<<<<<<<< * * def _notify_loop(): */ __pyx_tuple__54 = PyTuple_Pack(1, __pyx_kp_u_NoLockManager_instances_can_t_be); if (unlikely(!__pyx_tuple__54)) __PYX_ERR(2, 256, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__54); __Pyx_GIVEREF(__pyx_tuple__54); /* "src/misc.pxi":330 * * def __getstate__(self): * raise PicklingError("RequestContext instances can't be pickled") # <<<<<<<<<<<<<< * * @cython.freelist(10) */ __pyx_tuple__55 = PyTuple_Pack(1, __pyx_kp_u_RequestContext_instances_can_t_b); if (unlikely(!__pyx_tuple__55)) __PYX_ERR(2, 330, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__55); __Pyx_GIVEREF(__pyx_tuple__55); /* "src/misc.pxi":355 * * def __getstate__(self): * raise PicklingError("SetattrFields instances can't be pickled") # <<<<<<<<<<<<<< * * @cython.freelist(30) */ __pyx_tuple__56 = PyTuple_Pack(1, __pyx_kp_u_SetattrFields_instances_can_t_be); if (unlikely(!__pyx_tuple__56)) __PYX_ERR(2, 355, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__56); __Pyx_GIVEREF(__pyx_tuple__56); /* "src/misc.pxi":525 * def __getstate__(self): * state = dict() * for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', # <<<<<<<<<<<<<< * 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', * 'st_size', 'st_blksize', 'st_blocks', 'st_atime_ns', */ __pyx_tuple__57 = PyTuple_Pack(16, __pyx_n_u_st_ino, __pyx_n_u_generation, __pyx_n_u_entry_timeout, __pyx_n_u_attr_timeout, __pyx_n_u_st_mode, __pyx_n_u_st_nlink, __pyx_n_u_st_uid, __pyx_n_u_st_gid, __pyx_n_u_st_rdev, __pyx_n_u_st_size, __pyx_n_u_st_blksize, __pyx_n_u_st_blocks, __pyx_n_u_st_atime_ns, __pyx_n_u_st_ctime_ns, __pyx_n_u_st_mtime_ns, __pyx_n_u_st_birthtime_ns); if (unlikely(!__pyx_tuple__57)) __PYX_ERR(2, 525, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__57); __Pyx_GIVEREF(__pyx_tuple__57); /* "src/misc.pxi":616 * def __getstate__(self): * state = dict() * for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', # <<<<<<<<<<<<<< * 'f_bavail', 'f_files', 'f_ffree', 'f_favail', * 'f_namemax'): */ __pyx_tuple__58 = PyTuple_Pack(9, __pyx_n_u_f_bsize, __pyx_n_u_f_frsize, __pyx_n_u_f_blocks, __pyx_n_u_f_bfree, __pyx_n_u_f_bavail, __pyx_n_u_f_files, __pyx_n_u_f_ffree, __pyx_n_u_f_favail, __pyx_n_u_f_namemax); if (unlikely(!__pyx_tuple__58)) __PYX_ERR(2, 616, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__58); __Pyx_GIVEREF(__pyx_tuple__58); /* "src/misc.pxi":666 * len_ = fuse_buf_size(src) - src.off * if len_ > PY_SSIZE_T_MAX: * raise OverflowError('Value too long to convert to Python') # <<<<<<<<<<<<<< * buf = PyBytes_FromStringAndSize(NULL, len_) * dst.count = 1 */ __pyx_tuple__59 = PyTuple_Pack(1, __pyx_kp_u_Value_too_long_to_convert_to_Pyt); if (unlikely(!__pyx_tuple__59)) __PYX_ERR(2, 666, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__59); __Pyx_GIVEREF(__pyx_tuple__59); /* "src/fuse_api.pxi":28 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * cdef dirent.DIR* dirp */ __pyx_tuple__60 = PyTuple_Pack(1, __pyx_kp_u_path_argument_must_be_of_type_s); if (unlikely(!__pyx_tuple__60)) __PYX_ERR(3, 28, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__60); __Pyx_GIVEREF(__pyx_tuple__60); /* "src/fuse_api.pxi":82 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * if not isinstance(name, str_t): */ __pyx_tuple__61 = PyTuple_Pack(1, __pyx_kp_u_path_argument_must_be_of_type_s); if (unlikely(!__pyx_tuple__61)) __PYX_ERR(3, 82, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__61); __Pyx_GIVEREF(__pyx_tuple__61); /* "src/fuse_api.pxi":85 * * if not isinstance(name, str_t): * raise TypeError('*name* argument must be of type str') # <<<<<<<<<<<<<< * * if namespace not in ('system', 'user'): */ __pyx_tuple__62 = PyTuple_Pack(1, __pyx_kp_u_name_argument_must_be_of_type_s); if (unlikely(!__pyx_tuple__62)) __PYX_ERR(3, 85, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__62); __Pyx_GIVEREF(__pyx_tuple__62); /* "src/fuse_api.pxi":139 * * if not isinstance(path, str_t): * raise TypeError('*path* argument must be of type str') # <<<<<<<<<<<<<< * * if not isinstance(name, str_t): */ __pyx_tuple__63 = PyTuple_Pack(1, __pyx_kp_u_path_argument_must_be_of_type_s); if (unlikely(!__pyx_tuple__63)) __PYX_ERR(3, 139, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__63); __Pyx_GIVEREF(__pyx_tuple__63); /* "src/fuse_api.pxi":142 * * if not isinstance(name, str_t): * raise TypeError('*name* argument must be of type str') # <<<<<<<<<<<<<< * * if namespace not in ('system', 'user'): */ __pyx_tuple__64 = PyTuple_Pack(1, __pyx_kp_u_name_argument_must_be_of_type_s); if (unlikely(!__pyx_tuple__64)) __PYX_ERR(3, 142, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__64); __Pyx_GIVEREF(__pyx_tuple__64); /* "src/fuse_api.pxi":245 * ''' * * log.debug('Initializing llfuse') # <<<<<<<<<<<<<< * cdef fuse_args f_args * */ __pyx_tuple__66 = PyTuple_Pack(1, __pyx_kp_u_Initializing_llfuse); if (unlikely(!__pyx_tuple__66)) __PYX_ERR(3, 245, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__66); __Pyx_GIVEREF(__pyx_tuple__66); /* "src/fuse_api.pxi":249 * * if not isinstance(mountpoint, str_t): * raise TypeError('*mountpoint_* argument must be of type str') # <<<<<<<<<<<<<< * * global operations */ __pyx_tuple__67 = PyTuple_Pack(1, __pyx_kp_u_mountpoint__argument_must_be_of); if (unlikely(!__pyx_tuple__67)) __PYX_ERR(3, 249, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__67); __Pyx_GIVEREF(__pyx_tuple__67); /* "src/fuse_api.pxi":261 * * make_fuse_args(options, &f_args) * log.debug('Calling fuse_mount') # <<<<<<<<<<<<<< * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: */ __pyx_tuple__68 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_mount); if (unlikely(!__pyx_tuple__68)) __PYX_ERR(3, 261, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__68); __Pyx_GIVEREF(__pyx_tuple__68); /* "src/fuse_api.pxi":264 * channel = fuse_mount(mountpoint_b, &f_args) * if not channel: * raise RuntimeError('fuse_mount failed') # <<<<<<<<<<<<<< * * log.debug('Calling fuse_lowlevel_new') */ __pyx_tuple__69 = PyTuple_Pack(1, __pyx_kp_u_fuse_mount_failed); if (unlikely(!__pyx_tuple__69)) __PYX_ERR(3, 264, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__69); __Pyx_GIVEREF(__pyx_tuple__69); /* "src/fuse_api.pxi":266 * raise RuntimeError('fuse_mount failed') * * log.debug('Calling fuse_lowlevel_new') # <<<<<<<<<<<<<< * init_fuse_ops() * session = fuse_lowlevel_new(&f_args, &fuse_ops, sizeof(fuse_ops), NULL) */ __pyx_tuple__70 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_lowlevel_new); if (unlikely(!__pyx_tuple__70)) __PYX_ERR(3, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__70); __Pyx_GIVEREF(__pyx_tuple__70); /* "src/fuse_api.pxi":271 * if not session: * fuse_unmount(mountpoint_b, channel) * raise RuntimeError("fuse_lowlevel_new() failed") # <<<<<<<<<<<<<< * * log.debug('Calling fuse_session_add_chan') */ __pyx_tuple__71 = PyTuple_Pack(1, __pyx_kp_u_fuse_lowlevel_new_failed); if (unlikely(!__pyx_tuple__71)) __PYX_ERR(3, 271, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__71); __Pyx_GIVEREF(__pyx_tuple__71); /* "src/fuse_api.pxi":273 * raise RuntimeError("fuse_lowlevel_new() failed") * * log.debug('Calling fuse_session_add_chan') # <<<<<<<<<<<<<< * fuse_session_add_chan(session, channel) * */ __pyx_tuple__72 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_session_add_chan); if (unlikely(!__pyx_tuple__72)) __PYX_ERR(3, 273, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__72); __Pyx_GIVEREF(__pyx_tuple__72); /* "src/fuse_api.pxi":306 * * if session == NULL: * raise RuntimeError('Need to call init() before main()') # <<<<<<<<<<<<<< * * if workers == 0: */ __pyx_tuple__73 = PyTuple_Pack(1, __pyx_kp_u_Need_to_call_init_before_main); if (unlikely(!__pyx_tuple__73)) __PYX_ERR(3, 306, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__73); __Pyx_GIVEREF(__pyx_tuple__73); /* "src/fuse_api.pxi":309 * * if workers == 0: * raise ValueError('No workers is not a good idea') # <<<<<<<<<<<<<< * * if workers is None: */ __pyx_tuple__74 = PyTuple_Pack(1, __pyx_kp_u_No_workers_is_not_a_good_idea); if (unlikely(!__pyx_tuple__74)) __PYX_ERR(3, 309, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__74); __Pyx_GIVEREF(__pyx_tuple__74); /* "src/fuse_api.pxi":330 * on_exit.callback(lambda: fuse_session_reset(session)) * exc_info = None * log.debug('Calling fuse_session_loop') # <<<<<<<<<<<<<< * if workers == 1: * session_loop_single() */ __pyx_tuple__75 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_session_loop); if (unlikely(!__pyx_tuple__75)) __PYX_ERR(3, 330, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__75); __Pyx_GIVEREF(__pyx_tuple__75); /* "src/fuse_api.pxi":318 * # for "regular exit". * exit_reason = signal.SIGKILL * with contextlib.ExitStack() as on_exit: # <<<<<<<<<<<<<< * set_signal_handlers() * on_exit.callback(lambda: restore_signal_handlers()) */ __pyx_tuple__76 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__76)) __PYX_ERR(3, 318, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__76); __Pyx_GIVEREF(__pyx_tuple__76); /* "src/fuse_api.pxi":338 * if exc_info: * # Re-raise expression from request handler * log.debug('Terminated main loop because request handler raised exception, re-raising..') # <<<<<<<<<<<<<< * tmp = exc_info * exc_info = None */ __pyx_tuple__77 = PyTuple_Pack(1, __pyx_kp_u_Terminated_main_loop_because_req); if (unlikely(!__pyx_tuple__77)) __PYX_ERR(3, 338, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__77); __Pyx_GIVEREF(__pyx_tuple__77); /* "src/fuse_api.pxi":423 * exc_info = sys.exc_info() * else: * log.exception('Only one exception can be re-raised, the following ' # <<<<<<<<<<<<<< * 'exception will be lost:') * pthread_mutex_unlock(&exc_info_mutex) */ __pyx_tuple__78 = PyTuple_Pack(1, __pyx_kp_u_Only_one_exception_can_be_re_rai_2); if (unlikely(!__pyx_tuple__78)) __PYX_ERR(3, 423, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__78); __Pyx_GIVEREF(__pyx_tuple__78); /* "src/fuse_api.pxi":515 * global exc_info * * log.debug('Calling fuse_session_remove_chan') # <<<<<<<<<<<<<< * fuse_session_remove_chan(channel) * log.debug('Calling fuse_session_destroy') */ __pyx_tuple__79 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_session_remove_chan); if (unlikely(!__pyx_tuple__79)) __PYX_ERR(3, 515, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__79); __Pyx_GIVEREF(__pyx_tuple__79); /* "src/fuse_api.pxi":517 * log.debug('Calling fuse_session_remove_chan') * fuse_session_remove_chan(channel) * log.debug('Calling fuse_session_destroy') # <<<<<<<<<<<<<< * fuse_session_destroy(session) * */ __pyx_tuple__80 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_session_destroy); if (unlikely(!__pyx_tuple__80)) __PYX_ERR(3, 517, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__80); __Pyx_GIVEREF(__pyx_tuple__80); /* "src/fuse_api.pxi":521 * * if unmount: * log.debug('Calling fuse_unmount') # <<<<<<<<<<<<<< * fuse_unmount(mountpoint_b, channel) * else: */ __pyx_tuple__81 = PyTuple_Pack(1, __pyx_kp_u_Calling_fuse_unmount); if (unlikely(!__pyx_tuple__81)) __PYX_ERR(3, 521, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__81); __Pyx_GIVEREF(__pyx_tuple__81); /* "src/fuse_api.pxi":640 * with open('/proc/%d/status' % pid, 'r') as fh: * for line in fh: * if line.startswith('Groups:'): # <<<<<<<<<<<<<< * break * else: */ __pyx_tuple__82 = PyTuple_Pack(1, __pyx_kp_u_Groups); if (unlikely(!__pyx_tuple__82)) __PYX_ERR(3, 640, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__82); __Pyx_GIVEREF(__pyx_tuple__82); /* "src/fuse_api.pxi":638 * ''' * * with open('/proc/%d/status' % pid, 'r') as fh: # <<<<<<<<<<<<<< * for line in fh: * if line.startswith('Groups:'): */ __pyx_tuple__83 = PyTuple_Pack(3, Py_None, Py_None, Py_None); if (unlikely(!__pyx_tuple__83)) __PYX_ERR(3, 638, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__83); __Pyx_GIVEREF(__pyx_tuple__83); /* "src/fuse_api.pxi":645 * raise RuntimeError("Unable to parse %s" % fh.name) * gids = set() * for x in line.split()[1:]: # <<<<<<<<<<<<<< * gids.add(int(x)) * */ __pyx_slice__84 = PySlice_New(__pyx_int_1, Py_None, Py_None); if (unlikely(!__pyx_slice__84)) __PYX_ERR(3, 645, __pyx_L1_error) __Pyx_GOTREF(__pyx_slice__84); __Pyx_GIVEREF(__pyx_slice__84); /* "llfuse.pyx":130 * ################## * * log = logging.getLogger("llfuse") # <<<<<<<<<<<<<< * fse = sys.getfilesystemencoding() * */ __pyx_tuple__85 = PyTuple_Pack(1, __pyx_n_u_llfuse); if (unlikely(!__pyx_tuple__85)) __PYX_ERR(4, 130, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__85); __Pyx_GIVEREF(__pyx_tuple__85); /* "src/operations.pxi":28 * ''' * * def init(self): # <<<<<<<<<<<<<< * '''Initialize operations * */ __pyx_tuple__86 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__86)) __PYX_ERR(0, 28, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__86); __Pyx_GIVEREF(__pyx_tuple__86); __pyx_codeobj__87 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__86, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_init, 28, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__87)) __PYX_ERR(0, 28, __pyx_L1_error) /* "src/operations.pxi":38 * pass * * def destroy(self): # <<<<<<<<<<<<<< * '''Clean up operations. * */ __pyx_tuple__88 = PyTuple_Pack(1, __pyx_n_s_self); if (unlikely(!__pyx_tuple__88)) __PYX_ERR(0, 38, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__88); __Pyx_GIVEREF(__pyx_tuple__88); __pyx_codeobj__89 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__88, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_destroy, 38, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__89)) __PYX_ERR(0, 38, __pyx_L1_error) /* "src/operations.pxi":50 * pass * * def lookup(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Look up a directory entry by name and get its attributes. * */ __pyx_tuple__90 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__90)) __PYX_ERR(0, 50, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__90); __Pyx_GIVEREF(__pyx_tuple__90); __pyx_codeobj__91 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__90, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_lookup, 50, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__91)) __PYX_ERR(0, 50, __pyx_L1_error) /* "src/operations.pxi":73 * raise FUSEError(errno.ENOSYS) * * def forget(self, inode_list): # <<<<<<<<<<<<<< * '''Decrease lookup counts for inodes in *inode_list* * */ __pyx_tuple__92 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_inode_list); if (unlikely(!__pyx_tuple__92)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__92); __Pyx_GIVEREF(__pyx_tuple__92); __pyx_codeobj__93 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__92, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_forget, 73, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__93)) __PYX_ERR(0, 73, __pyx_L1_error) /* "src/operations.pxi":96 * pass * * def getattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get attributes for *inode* * */ __pyx_tuple__94 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__94)) __PYX_ERR(0, 96, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__94); __Pyx_GIVEREF(__pyx_tuple__94); __pyx_codeobj__95 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__94, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_getattr, 96, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__95)) __PYX_ERR(0, 96, __pyx_L1_error) /* "src/operations.pxi":109 * * * def setattr(self, inode, attr, fields, fh, ctx): # <<<<<<<<<<<<<< * '''Change attributes of *inode* * */ __pyx_tuple__96 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_attr, __pyx_n_s_fields, __pyx_n_s_fh, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__96)) __PYX_ERR(0, 109, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__96); __Pyx_GIVEREF(__pyx_tuple__96); __pyx_codeobj__97 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__96, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_setattr, 109, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__97)) __PYX_ERR(0, 109, __pyx_L1_error) /* "src/operations.pxi":136 * raise FUSEError(errno.ENOSYS) * * def readlink(self, inode, ctx): # <<<<<<<<<<<<<< * '''Return target of symbolic link *inode*. * */ __pyx_tuple__98 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__98)) __PYX_ERR(0, 136, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__98); __Pyx_GIVEREF(__pyx_tuple__98); __pyx_codeobj__99 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__98, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_readlink, 136, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__99)) __PYX_ERR(0, 136, __pyx_L1_error) /* "src/operations.pxi":145 * * * def mknod(self, parent_inode, name, mode, rdev, ctx): # <<<<<<<<<<<<<< * '''Create (possibly special) file * */ __pyx_tuple__100 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_mode, __pyx_n_s_rdev, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__100)) __PYX_ERR(0, 145, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__100); __Pyx_GIVEREF(__pyx_tuple__100); __pyx_codeobj__101 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__100, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_mknod, 145, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__101)) __PYX_ERR(0, 145, __pyx_L1_error) /* "src/operations.pxi":163 * raise FUSEError(errno.ENOSYS) * * def mkdir(self, parent_inode, name, mode, ctx): # <<<<<<<<<<<<<< * '''Create a directory * */ __pyx_tuple__102 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_mode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__102)) __PYX_ERR(0, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__102); __Pyx_GIVEREF(__pyx_tuple__102); __pyx_codeobj__103 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__102, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_mkdir, 163, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__103)) __PYX_ERR(0, 163, __pyx_L1_error) /* "src/operations.pxi":179 * raise FUSEError(errno.ENOSYS) * * def unlink(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove a (possibly special) file * */ __pyx_tuple__104 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__104)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__104); __Pyx_GIVEREF(__pyx_tuple__104); __pyx_codeobj__105 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__104, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_unlink, 179, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__105)) __PYX_ERR(0, 179, __pyx_L1_error) /* "src/operations.pxi":201 * raise FUSEError(errno.ENOSYS) * * def rmdir(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove directory *name* * */ __pyx_tuple__106 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__106)) __PYX_ERR(0, 201, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__106); __Pyx_GIVEREF(__pyx_tuple__106); __pyx_codeobj__107 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__106, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_rmdir, 201, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__107)) __PYX_ERR(0, 201, __pyx_L1_error) /* "src/operations.pxi":225 * raise FUSEError(errno.ENOSYS) * * def symlink(self, parent_inode, name, target, ctx): # <<<<<<<<<<<<<< * '''Create a symbolic link * */ __pyx_tuple__108 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_target, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__108)) __PYX_ERR(0, 225, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__108); __Pyx_GIVEREF(__pyx_tuple__108); __pyx_codeobj__109 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__108, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_symlink, 225, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__109)) __PYX_ERR(0, 225, __pyx_L1_error) /* "src/operations.pxi":241 * raise FUSEError(errno.ENOSYS) * * def rename(self, parent_inode_old, name_old, parent_inode_new, # <<<<<<<<<<<<<< * name_new, ctx): * '''Rename a directory entry. */ __pyx_tuple__110 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_parent_inode_old, __pyx_n_s_name_old, __pyx_n_s_parent_inode_new, __pyx_n_s_name_new, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__110)) __PYX_ERR(0, 241, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__110); __Pyx_GIVEREF(__pyx_tuple__110); __pyx_codeobj__111 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__110, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_rename, 241, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__111)) __PYX_ERR(0, 241, __pyx_L1_error) /* "src/operations.pxi":266 * raise FUSEError(errno.ENOSYS) * * def link(self, inode, new_parent_inode, new_name, ctx): # <<<<<<<<<<<<<< * '''Create directory entry *name* in *parent_inode* refering to *inode*. * */ __pyx_tuple__112 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_new_parent_inode, __pyx_n_s_new_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__112)) __PYX_ERR(0, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__112); __Pyx_GIVEREF(__pyx_tuple__112); __pyx_codeobj__113 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__112, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_link, 266, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__113)) __PYX_ERR(0, 266, __pyx_L1_error) /* "src/operations.pxi":280 * raise FUSEError(errno.ENOSYS) * * def open(self, inode, flags, ctx): # <<<<<<<<<<<<<< * '''Open a inode *inode* with *flags*. * */ __pyx_tuple__114 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_flags, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__114)) __PYX_ERR(0, 280, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__114); __Pyx_GIVEREF(__pyx_tuple__114); __pyx_codeobj__115 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__114, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_open, 280, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__115)) __PYX_ERR(0, 280, __pyx_L1_error) /* "src/operations.pxi":296 * raise FUSEError(errno.ENOSYS) * * def read(self, fh, off, size): # <<<<<<<<<<<<<< * '''Read *size* bytes from *fh* at position *off* * */ __pyx_tuple__116 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_fh, __pyx_n_s_off, __pyx_n_s_size); if (unlikely(!__pyx_tuple__116)) __PYX_ERR(0, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__116); __Pyx_GIVEREF(__pyx_tuple__116); __pyx_codeobj__117 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__116, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_read, 296, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__117)) __PYX_ERR(0, 296, __pyx_L1_error) /* "src/operations.pxi":309 * raise FUSEError(errno.ENOSYS) * * def write(self, fh, off, buf): # <<<<<<<<<<<<<< * '''Write *buf* into *fh* at *off* * */ __pyx_tuple__118 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_fh, __pyx_n_s_off, __pyx_n_s_buf); if (unlikely(!__pyx_tuple__118)) __PYX_ERR(0, 309, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__118); __Pyx_GIVEREF(__pyx_tuple__118); __pyx_codeobj__119 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__118, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_write, 309, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__119)) __PYX_ERR(0, 309, __pyx_L1_error) /* "src/operations.pxi":323 * raise FUSEError(errno.ENOSYS) * * def flush(self, fh): # <<<<<<<<<<<<<< * '''Handle close() syscall. * */ __pyx_tuple__120 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_fh); if (unlikely(!__pyx_tuple__120)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__120); __Pyx_GIVEREF(__pyx_tuple__120); __pyx_codeobj__121 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__120, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_flush, 323, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__121)) __PYX_ERR(0, 323, __pyx_L1_error) /* "src/operations.pxi":336 * raise FUSEError(errno.ENOSYS) * * def release(self, fh): # <<<<<<<<<<<<<< * '''Release open file * */ __pyx_tuple__122 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_fh); if (unlikely(!__pyx_tuple__122)) __PYX_ERR(0, 336, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__122); __Pyx_GIVEREF(__pyx_tuple__122); __pyx_codeobj__123 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__122, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_release, 336, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__123)) __PYX_ERR(0, 336, __pyx_L1_error) /* "src/operations.pxi":354 * raise FUSEError(errno.ENOSYS) * * def fsync(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open file *fh* * */ __pyx_tuple__124 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_fh, __pyx_n_s_datasync); if (unlikely(!__pyx_tuple__124)) __PYX_ERR(0, 354, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__124); __Pyx_GIVEREF(__pyx_tuple__124); __pyx_codeobj__125 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__124, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_fsync, 354, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__125)) __PYX_ERR(0, 354, __pyx_L1_error) /* "src/operations.pxi":366 * raise FUSEError(errno.ENOSYS) * * def opendir(self, inode, ctx): # <<<<<<<<<<<<<< * '''Open the directory with inode *inode* * */ __pyx_tuple__126 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__126)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__126); __Pyx_GIVEREF(__pyx_tuple__126); __pyx_codeobj__127 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__126, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_opendir, 366, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__127)) __PYX_ERR(0, 366, __pyx_L1_error) /* "src/operations.pxi":379 * * * def readdir(self, fh, off): # <<<<<<<<<<<<<< * '''Read entries in open directory *fh*. * */ __pyx_tuple__128 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_fh, __pyx_n_s_off); if (unlikely(!__pyx_tuple__128)) __PYX_ERR(0, 379, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__128); __Pyx_GIVEREF(__pyx_tuple__128); __pyx_codeobj__129 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__128, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_readdir, 379, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__129)) __PYX_ERR(0, 379, __pyx_L1_error) /* "src/operations.pxi":403 * raise FUSEError(errno.ENOSYS) * * def releasedir(self, fh): # <<<<<<<<<<<<<< * '''Release open directory * */ __pyx_tuple__130 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_fh); if (unlikely(!__pyx_tuple__130)) __PYX_ERR(0, 403, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__130); __Pyx_GIVEREF(__pyx_tuple__130); __pyx_codeobj__131 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__130, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_releasedir, 403, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__131)) __PYX_ERR(0, 403, __pyx_L1_error) /* "src/operations.pxi":413 * raise FUSEError(errno.ENOSYS) * * def fsyncdir(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open directory *fh* * */ __pyx_tuple__132 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_fh, __pyx_n_s_datasync); if (unlikely(!__pyx_tuple__132)) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__132); __Pyx_GIVEREF(__pyx_tuple__132); __pyx_codeobj__133 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__132, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_fsyncdir, 413, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__133)) __PYX_ERR(0, 413, __pyx_L1_error) /* "src/operations.pxi":422 * raise FUSEError(errno.ENOSYS) * * def statfs(self, ctx): # <<<<<<<<<<<<<< * '''Get file system statistics * */ __pyx_tuple__134 = PyTuple_Pack(2, __pyx_n_s_self, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__134)) __PYX_ERR(0, 422, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__134); __Pyx_GIVEREF(__pyx_tuple__134); __pyx_codeobj__135 = (PyObject*)__Pyx_PyCode_New(2, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__134, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_statfs, 422, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__135)) __PYX_ERR(0, 422, __pyx_L1_error) /* "src/operations.pxi":432 * raise FUSEError(errno.ENOSYS) * * def stacktrace(self): # <<<<<<<<<<<<<< * '''Asynchronous debugging * */ __pyx_tuple__136 = PyTuple_Pack(10, __pyx_n_s_self, __pyx_n_s_sys, __pyx_n_s_traceback, __pyx_n_s_code, __pyx_n_s_threadId, __pyx_n_s_frame, __pyx_n_s_filename, __pyx_n_s_lineno, __pyx_n_s_name, __pyx_n_s_line); if (unlikely(!__pyx_tuple__136)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__136); __Pyx_GIVEREF(__pyx_tuple__136); __pyx_codeobj__137 = (PyObject*)__Pyx_PyCode_New(1, 0, 10, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__136, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_stacktrace, 432, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__137)) __PYX_ERR(0, 432, __pyx_L1_error) /* "src/operations.pxi":455 * log.error("\n".join(code)) * * def setxattr(self, inode, name, value, ctx): # <<<<<<<<<<<<<< * '''Set extended attribute *name* of *inode* to *value*. * */ __pyx_tuple__138 = PyTuple_Pack(5, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_name, __pyx_n_s_value, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__138)) __PYX_ERR(0, 455, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__138); __Pyx_GIVEREF(__pyx_tuple__138); __pyx_codeobj__139 = (PyObject*)__Pyx_PyCode_New(5, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__138, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_setxattr, 455, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__139)) __PYX_ERR(0, 455, __pyx_L1_error) /* "src/operations.pxi":467 * raise FUSEError(errno.ENOSYS) * * def getxattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Return extended attribute *name* of *inode* * */ __pyx_tuple__140 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__140)) __PYX_ERR(0, 467, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__140); __Pyx_GIVEREF(__pyx_tuple__140); __pyx_codeobj__141 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__140, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_getxattr, 467, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__141)) __PYX_ERR(0, 467, __pyx_L1_error) /* "src/operations.pxi":479 * raise FUSEError(errno.ENOSYS) * * def listxattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get list of extended attributes for *inode* * */ __pyx_tuple__142 = PyTuple_Pack(3, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__142)) __PYX_ERR(0, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__142); __Pyx_GIVEREF(__pyx_tuple__142); __pyx_codeobj__143 = (PyObject*)__Pyx_PyCode_New(3, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__142, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_listxattr, 479, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__143)) __PYX_ERR(0, 479, __pyx_L1_error) /* "src/operations.pxi":490 * raise FUSEError(errno.ENOSYS) * * def removexattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove extended attribute *name* of *inode* * */ __pyx_tuple__144 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_name, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__144)) __PYX_ERR(0, 490, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__144); __Pyx_GIVEREF(__pyx_tuple__144); __pyx_codeobj__145 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__144, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_removexattr, 490, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__145)) __PYX_ERR(0, 490, __pyx_L1_error) /* "src/operations.pxi":503 * * * def access(self, inode, mode, ctx): # <<<<<<<<<<<<<< * '''Check if requesting process has *mode* rights on *inode*. * */ __pyx_tuple__146 = PyTuple_Pack(4, __pyx_n_s_self, __pyx_n_s_inode, __pyx_n_s_mode, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__146)) __PYX_ERR(0, 503, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__146); __Pyx_GIVEREF(__pyx_tuple__146); __pyx_codeobj__147 = (PyObject*)__Pyx_PyCode_New(4, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__146, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_access, 503, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__147)) __PYX_ERR(0, 503, __pyx_L1_error) /* "src/operations.pxi":519 * raise FUSEError(errno.ENOSYS) * * def create(self, parent_inode, name, mode, flags, ctx): # <<<<<<<<<<<<<< * '''Create a file with permissions *mode* and open it with *flags* * */ __pyx_tuple__148 = PyTuple_Pack(6, __pyx_n_s_self, __pyx_n_s_parent_inode, __pyx_n_s_name, __pyx_n_s_mode, __pyx_n_s_flags, __pyx_n_s_ctx); if (unlikely(!__pyx_tuple__148)) __PYX_ERR(0, 519, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__148); __Pyx_GIVEREF(__pyx_tuple__148); __pyx_codeobj__149 = (PyObject*)__Pyx_PyCode_New(6, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__148, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho, __pyx_n_s_create, 519, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__149)) __PYX_ERR(0, 519, __pyx_L1_error) /* "src/misc.pxi":258 * raise PicklingError("NoLockManager instances can't be pickled") * * def _notify_loop(): # <<<<<<<<<<<<<< * '''Read notifications from queue and send to FUSE kernel module''' * */ __pyx_tuple__150 = PyTuple_Pack(3, __pyx_n_s_len, __pyx_n_s_cname, __pyx_n_s_req); if (unlikely(!__pyx_tuple__150)) __PYX_ERR(2, 258, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__150); __Pyx_GIVEREF(__pyx_tuple__150); __pyx_codeobj__151 = (PyObject*)__Pyx_PyCode_New(0, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__150, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_2, __pyx_n_s_notify_loop, 258, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__151)) __PYX_ERR(2, 258, __pyx_L1_error) /* "src/fuse_api.pxi":14 * ''' * * def listdir(path): # <<<<<<<<<<<<<< * '''Like `os.listdir`, but releases the GIL. * */ __pyx_tuple__152 = PyTuple_Pack(6, __pyx_n_s_path, __pyx_n_s_dirp, __pyx_n_s_res, __pyx_n_s_buf, __pyx_n_s_path_b, __pyx_n_s_names); if (unlikely(!__pyx_tuple__152)) __PYX_ERR(3, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__152); __Pyx_GIVEREF(__pyx_tuple__152); __pyx_codeobj__153 = (PyObject*)__Pyx_PyCode_New(1, 0, 6, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__152, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_listdir, 14, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__153)) __PYX_ERR(3, 14, __pyx_L1_error) /* "src/fuse_api.pxi":66 * * * def setxattr(path, name, bytes value, namespace='user'): # <<<<<<<<<<<<<< * '''Set extended attribute * */ __pyx_tuple__154 = PyTuple_Pack(12, __pyx_n_s_path, __pyx_n_s_name, __pyx_n_s_value, __pyx_n_s_namespace, __pyx_n_s_ret, __pyx_n_s_len, __pyx_n_s_cvalue, __pyx_n_s_cpath, __pyx_n_s_cname, __pyx_n_s_cnamespace, __pyx_n_s_path_b, __pyx_n_s_name_b); if (unlikely(!__pyx_tuple__154)) __PYX_ERR(3, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__154); __Pyx_GIVEREF(__pyx_tuple__154); __pyx_codeobj__155 = (PyObject*)__Pyx_PyCode_New(4, 0, 12, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__154, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_setxattr, 66, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__155)) __PYX_ERR(3, 66, __pyx_L1_error) /* "src/fuse_api.pxi":117 * * * def getxattr(path, name, size_t size_guess=128, namespace='user'): # <<<<<<<<<<<<<< * '''Get extended attribute * */ __pyx_tuple__156 = PyTuple_Pack(12, __pyx_n_s_path, __pyx_n_s_name, __pyx_n_s_size_guess, __pyx_n_s_namespace, __pyx_n_s_ret, __pyx_n_s_buf, __pyx_n_s_cpath, __pyx_n_s_cname, __pyx_n_s_bufsize, __pyx_n_s_cnamespace, __pyx_n_s_path_b, __pyx_n_s_name_b); if (unlikely(!__pyx_tuple__156)) __PYX_ERR(3, 117, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__156); __Pyx_GIVEREF(__pyx_tuple__156); __pyx_codeobj__157 = (PyObject*)__Pyx_PyCode_New(4, 0, 12, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__156, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_getxattr, 117, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__157)) __PYX_ERR(3, 117, __pyx_L1_error) /* "src/fuse_api.pxi":217 * # * if os.uname()[0] == 'Darwin': * default_options = frozenset(('big_writes', 'default_permissions', # <<<<<<<<<<<<<< * 'no_splice_read', 'splice_write', 'splice_move')) * else: */ __pyx_tuple__158 = PyTuple_Pack(5, __pyx_n_u_big_writes, __pyx_n_u_default_permissions, __pyx_n_u_no_splice_read, __pyx_n_u_splice_write, __pyx_n_u_splice_move); if (unlikely(!__pyx_tuple__158)) __PYX_ERR(3, 217, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__158); __Pyx_GIVEREF(__pyx_tuple__158); /* "src/fuse_api.pxi":220 * 'no_splice_read', 'splice_write', 'splice_move')) * else: * default_options = frozenset(('big_writes', 'nonempty', 'default_permissions', # <<<<<<<<<<<<<< * 'no_splice_read', 'splice_write', 'splice_move')) * */ __pyx_tuple__159 = PyTuple_Pack(6, __pyx_n_u_big_writes, __pyx_n_u_nonempty, __pyx_n_u_default_permissions, __pyx_n_u_no_splice_read, __pyx_n_u_splice_write, __pyx_n_u_splice_move); if (unlikely(!__pyx_tuple__159)) __PYX_ERR(3, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__159); __Pyx_GIVEREF(__pyx_tuple__159); /* "src/fuse_api.pxi":223 * 'no_splice_read', 'splice_write', 'splice_move')) * * def init(ops, mountpoint, options=default_options): # <<<<<<<<<<<<<< * '''Initialize and mount FUSE file system * */ __pyx_tuple__160 = PyTuple_Pack(4, __pyx_n_s_ops, __pyx_n_s_mountpoint, __pyx_n_s_options, __pyx_n_s_f_args); if (unlikely(!__pyx_tuple__160)) __PYX_ERR(3, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__160); __Pyx_GIVEREF(__pyx_tuple__160); __pyx_codeobj__161 = (PyObject*)__Pyx_PyCode_New(3, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__160, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_init, 223, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__161)) __PYX_ERR(3, 223, __pyx_L1_error) /* "src/fuse_api.pxi":278 * pthread_mutex_init(&exc_info_mutex, NULL) * * def main(workers=None): # <<<<<<<<<<<<<< * '''Run FUSE main loop * */ __pyx_tuple__162 = PyTuple_Pack(4, __pyx_n_s_workers, __pyx_n_s_on_exit, __pyx_n_s_t, __pyx_n_s_tmp); if (unlikely(!__pyx_tuple__162)) __PYX_ERR(3, 278, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__162); __Pyx_GIVEREF(__pyx_tuple__162); __pyx_codeobj__163 = (PyObject*)__Pyx_PyCode_New(1, 0, 4, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__162, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_main_2, 278, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__163)) __PYX_ERR(3, 278, __pyx_L1_error) /* "src/fuse_api.pxi":491 * * * def close(unmount=True): # <<<<<<<<<<<<<< * '''Clean up and ensure filesystem is unmounted * */ __pyx_tuple__164 = PyTuple_Pack(2, __pyx_n_s_unmount, __pyx_n_s_tmp); if (unlikely(!__pyx_tuple__164)) __PYX_ERR(3, 491, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__164); __Pyx_GIVEREF(__pyx_tuple__164); __pyx_codeobj__165 = (PyObject*)__Pyx_PyCode_New(1, 0, 2, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__164, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_close, 491, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__165)) __PYX_ERR(3, 491, __pyx_L1_error) /* "src/fuse_api.pxi":543 * raise tmp[1].with_traceback(tmp[2]) * * def invalidate_inode(fuse_ino_t inode, attr_only=False): # <<<<<<<<<<<<<< * '''Invalidate cache for *inode* * */ __pyx_tuple__166 = PyTuple_Pack(3, __pyx_n_s_inode, __pyx_n_s_attr_only, __pyx_n_s_req); if (unlikely(!__pyx_tuple__166)) __PYX_ERR(3, 543, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__166); __Pyx_GIVEREF(__pyx_tuple__166); __pyx_codeobj__167 = (PyObject*)__Pyx_PyCode_New(2, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__166, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_invalidate_inode, 543, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__167)) __PYX_ERR(3, 543, __pyx_L1_error) /* "src/fuse_api.pxi":559 * _notify_queue.put(req) * * def invalidate_entry(fuse_ino_t inode_p, bytes name): # <<<<<<<<<<<<<< * '''Invalidate directory entry * */ __pyx_tuple__168 = PyTuple_Pack(3, __pyx_n_s_inode_p, __pyx_n_s_name, __pyx_n_s_req); if (unlikely(!__pyx_tuple__168)) __PYX_ERR(3, 559, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__168); __Pyx_GIVEREF(__pyx_tuple__168); __pyx_codeobj__169 = (PyObject*)__Pyx_PyCode_New(2, 0, 3, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__168, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_invalidate_entry, 559, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__169)) __PYX_ERR(3, 559, __pyx_L1_error) /* "src/fuse_api.pxi":575 * _notify_queue.put(req) * * def get_ino_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bits available for inode numbers * */ __pyx_codeobj__170 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_get_ino_t_bits, 575, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__170)) __PYX_ERR(3, 575, __pyx_L1_error) /* "src/fuse_api.pxi":583 * return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 * * def get_off_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bytes available for file offsets * */ __pyx_codeobj__171 = (PyObject*)__Pyx_PyCode_New(0, 0, 0, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_get_off_t_bits, 583, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__171)) __PYX_ERR(3, 583, __pyx_L1_error) /* "src/fuse_api.pxi":591 * return sizeof(off_t) * 8 * * def notify_store(inode, offset, data): # <<<<<<<<<<<<<< * '''Store data in kernel page cache * */ __pyx_tuple__172 = PyTuple_Pack(9, __pyx_n_s_inode, __pyx_n_s_offset, __pyx_n_s_data, __pyx_n_s_ret, __pyx_n_s_ino, __pyx_n_s_off, __pyx_n_s_pybuf, __pyx_n_s_bufvec, __pyx_n_s_buf); if (unlikely(!__pyx_tuple__172)) __PYX_ERR(3, 591, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__172); __Pyx_GIVEREF(__pyx_tuple__172); __pyx_codeobj__173 = (PyObject*)__Pyx_PyCode_New(3, 0, 9, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__172, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_notify_store, 591, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__173)) __PYX_ERR(3, 591, __pyx_L1_error) /* "src/fuse_api.pxi":628 * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * * def get_sup_groups(pid): # <<<<<<<<<<<<<< * '''Return supplementary group ids of *pid* * */ __pyx_tuple__174 = PyTuple_Pack(5, __pyx_n_s_pid, __pyx_n_s_fh, __pyx_n_s_line, __pyx_n_s_gids, __pyx_n_s_x); if (unlikely(!__pyx_tuple__174)) __PYX_ERR(3, 628, __pyx_L1_error) __Pyx_GOTREF(__pyx_tuple__174); __Pyx_GIVEREF(__pyx_tuple__174); __pyx_codeobj__175 = (PyObject*)__Pyx_PyCode_New(1, 0, 5, 0, 0, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__174, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_home_nikratio_in_progress_pytho_3, __pyx_n_s_get_sup_groups, 628, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__175)) __PYX_ERR(3, 628, __pyx_L1_error) __Pyx_RefNannyFinishContext(); return 0; __pyx_L1_error:; __Pyx_RefNannyFinishContext(); return -1; } static int __Pyx_InitGlobals(void) { if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(4, 1, __pyx_L1_error); __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_int_5 = PyInt_FromLong(5); if (unlikely(!__pyx_int_5)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_int_30 = PyInt_FromLong(30); if (unlikely(!__pyx_int_30)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_int_1000 = PyInt_FromLong(1000); if (unlikely(!__pyx_int_1000)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_int_1000000000 = PyInt_FromLong(1000000000L); if (unlikely(!__pyx_int_1000000000)) __PYX_ERR(4, 1, __pyx_L1_error) return 0; __pyx_L1_error:; return -1; } #if PY_MAJOR_VERSION < 3 PyMODINIT_FUNC initllfuse(void); /*proto*/ PyMODINIT_FUNC initllfuse(void) #else PyMODINIT_FUNC PyInit_llfuse(void); /*proto*/ PyMODINIT_FUNC PyInit_llfuse(void) #endif { PyObject *__pyx_t_1 = NULL; PyObject *__pyx_t_2 = NULL; int __pyx_t_3; PyObject *__pyx_t_4 = NULL; PyObject *__pyx_t_5 = NULL; __Pyx_RefNannyDeclarations #if CYTHON_REFNANNY __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny"); if (!__Pyx_RefNanny) { PyErr_Clear(); __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny"); if (!__Pyx_RefNanny) Py_FatalError("failed to import 'refnanny' module"); } #endif __Pyx_RefNannySetupContext("PyMODINIT_FUNC PyInit_llfuse(void)", 0); if (__Pyx_check_binary_version() < 0) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(4, 1, __pyx_L1_error) #ifdef __Pyx_CyFunction_USED if (__pyx_CyFunction_init() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif #ifdef __Pyx_FusedFunction_USED if (__pyx_FusedFunction_init() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif #ifdef __Pyx_Coroutine_USED if (__pyx_Coroutine_init() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif #ifdef __Pyx_Generator_USED if (__pyx_Generator_init() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif #ifdef __Pyx_StopAsyncIteration_USED if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif /*--- Library function declarations ---*/ /*--- Threads initialization code ---*/ #if defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS #ifdef WITH_THREAD /* Python build with threading support? */ PyEval_InitThreads(); #endif #endif /*--- Module creation code ---*/ #if PY_MAJOR_VERSION < 3 __pyx_m = Py_InitModule4("llfuse", __pyx_methods, __pyx_k_llfuse_pxy_Copyright_2013_Nikol, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m); #else __pyx_m = PyModule_Create(&__pyx_moduledef); #endif if (unlikely(!__pyx_m)) __PYX_ERR(4, 1, __pyx_L1_error) __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(4, 1, __pyx_L1_error) Py_INCREF(__pyx_d); __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(4, 1, __pyx_L1_error) #if CYTHON_COMPILING_IN_PYPY Py_INCREF(__pyx_b); #endif if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(4, 1, __pyx_L1_error); /*--- Initialize various global constants etc. ---*/ if (__Pyx_InitGlobals() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT) if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif if (__pyx_module_is_main_llfuse) { if (PyObject_SetAttrString(__pyx_m, "__name__", __pyx_n_s_main) < 0) __PYX_ERR(4, 1, __pyx_L1_error) } #if PY_MAJOR_VERSION >= 3 { PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(4, 1, __pyx_L1_error) if (!PyDict_GetItemString(modules, "llfuse")) { if (unlikely(PyDict_SetItemString(modules, "llfuse", __pyx_m) < 0)) __PYX_ERR(4, 1, __pyx_L1_error) } } #endif /*--- Builtin init code ---*/ if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(4, 1, __pyx_L1_error) /*--- Constants init code ---*/ if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(4, 1, __pyx_L1_error) /*--- Global init code ---*/ __pyx_v_6llfuse_operations = Py_None; Py_INCREF(Py_None); __pyx_v_6llfuse_mountpoint_b = Py_None; Py_INCREF(Py_None); __pyx_v_6llfuse_exc_info = Py_None; Py_INCREF(Py_None); __pyx_v_6llfuse__notify_queue = Py_None; Py_INCREF(Py_None); /*--- Variable export code ---*/ /*--- Function export code ---*/ /*--- Type init code ---*/ if (PyType_Ready(&__pyx_type_6llfuse_Lock) < 0) __PYX_ERR(2, 139, __pyx_L1_error) __pyx_type_6llfuse_Lock.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "Lock", (PyObject *)&__pyx_type_6llfuse_Lock) < 0) __PYX_ERR(2, 139, __pyx_L1_error) __pyx_ptype_6llfuse_Lock = &__pyx_type_6llfuse_Lock; if (PyType_Ready(&__pyx_type_6llfuse_NoLockManager) < 0) __PYX_ERR(2, 242, __pyx_L1_error) __pyx_type_6llfuse_NoLockManager.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "NoLockManager", (PyObject *)&__pyx_type_6llfuse_NoLockManager) < 0) __PYX_ERR(2, 242, __pyx_L1_error) __pyx_ptype_6llfuse_NoLockManager = &__pyx_type_6llfuse_NoLockManager; if (PyType_Ready(&__pyx_type_6llfuse_RequestContext) < 0) __PYX_ERR(2, 317, __pyx_L1_error) __pyx_type_6llfuse_RequestContext.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "RequestContext", (PyObject *)&__pyx_type_6llfuse_RequestContext) < 0) __PYX_ERR(2, 317, __pyx_L1_error) __pyx_ptype_6llfuse_RequestContext = &__pyx_type_6llfuse_RequestContext; if (PyType_Ready(&__pyx_type_6llfuse_SetattrFields) < 0) __PYX_ERR(2, 333, __pyx_L1_error) __pyx_type_6llfuse_SetattrFields.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "SetattrFields", (PyObject *)&__pyx_type_6llfuse_SetattrFields) < 0) __PYX_ERR(2, 333, __pyx_L1_error) __pyx_ptype_6llfuse_SetattrFields = &__pyx_type_6llfuse_SetattrFields; if (PyType_Ready(&__pyx_type_6llfuse_EntryAttributes) < 0) __PYX_ERR(2, 358, __pyx_L1_error) __pyx_type_6llfuse_EntryAttributes.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "EntryAttributes", (PyObject *)&__pyx_type_6llfuse_EntryAttributes) < 0) __PYX_ERR(2, 358, __pyx_L1_error) __pyx_ptype_6llfuse_EntryAttributes = &__pyx_type_6llfuse_EntryAttributes; if (PyType_Ready(&__pyx_type_6llfuse_StatvfsData) < 0) __PYX_ERR(2, 538, __pyx_L1_error) __pyx_type_6llfuse_StatvfsData.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "StatvfsData", (PyObject *)&__pyx_type_6llfuse_StatvfsData) < 0) __PYX_ERR(2, 538, __pyx_L1_error) __pyx_ptype_6llfuse_StatvfsData = &__pyx_type_6llfuse_StatvfsData; __pyx_type_6llfuse_FUSEError.tp_base = (&((PyTypeObject*)PyExc_Exception)[0]); if (PyType_Ready(&__pyx_type_6llfuse_FUSEError) < 0) __PYX_ERR(2, 628, __pyx_L1_error) __pyx_type_6llfuse_FUSEError.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "FUSEError", (PyObject *)&__pyx_type_6llfuse_FUSEError) < 0) __PYX_ERR(2, 628, __pyx_L1_error) __pyx_ptype_6llfuse_FUSEError = &__pyx_type_6llfuse_FUSEError; if (PyType_Ready(&__pyx_type_6llfuse_NotifyRequest) < 0) __PYX_ERR(2, 653, __pyx_L1_error) __pyx_type_6llfuse_NotifyRequest.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "NotifyRequest", (PyObject *)&__pyx_type_6llfuse_NotifyRequest) < 0) __PYX_ERR(2, 653, __pyx_L1_error) __pyx_ptype_6llfuse_NotifyRequest = &__pyx_type_6llfuse_NotifyRequest; if (PyType_Ready(&__pyx_type_6llfuse_VoidPtrCapsule) < 0) __PYX_ERR(2, 684, __pyx_L1_error) __pyx_type_6llfuse_VoidPtrCapsule.tp_print = 0; if (PyObject_SetAttrString(__pyx_m, "VoidPtrCapsule", (PyObject *)&__pyx_type_6llfuse_VoidPtrCapsule) < 0) __PYX_ERR(2, 684, __pyx_L1_error) __pyx_ptype_6llfuse_VoidPtrCapsule = &__pyx_type_6llfuse_VoidPtrCapsule; /*--- Type import code ---*/ __pyx_ptype_7cpython_4type_type = __Pyx_ImportType(__Pyx_BUILTIN_MODULE_NAME, "type", #if CYTHON_COMPILING_IN_PYPY sizeof(PyTypeObject), #else sizeof(PyHeapTypeObject), #endif 0); if (unlikely(!__pyx_ptype_7cpython_4type_type)) __PYX_ERR(5, 9, __pyx_L1_error) /*--- Variable import code ---*/ /*--- Function import code ---*/ /*--- Execution code ---*/ #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED) if (__Pyx_patch_abc() < 0) __PYX_ERR(4, 1, __pyx_L1_error) #endif /* "llfuse.pyx":110 * ################ * * import os # <<<<<<<<<<<<<< * import logging * import sys */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_os, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 110, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_os, __pyx_t_1) < 0) __PYX_ERR(4, 110, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":111 * * import os * import logging # <<<<<<<<<<<<<< * import sys * import os.path */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_logging, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 111, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_logging, __pyx_t_1) < 0) __PYX_ERR(4, 111, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":112 * import os * import logging * import sys # <<<<<<<<<<<<<< * import os.path * import threading */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_sys, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 112, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_sys, __pyx_t_1) < 0) __PYX_ERR(4, 112, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":113 * import logging * import sys * import os.path # <<<<<<<<<<<<<< * import threading * from pickle import PicklingError */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_os_path, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 113, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_os, __pyx_t_1) < 0) __PYX_ERR(4, 113, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":114 * import sys * import os.path * import threading # <<<<<<<<<<<<<< * from pickle import PicklingError * */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_threading, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 114, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_threading, __pyx_t_1) < 0) __PYX_ERR(4, 114, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":115 * import os.path * import threading * from pickle import PicklingError # <<<<<<<<<<<<<< * * if PY_MAJOR_VERSION < 3: */ __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 115, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_n_s_PicklingError); __Pyx_GIVEREF(__pyx_n_s_PicklingError); PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_PicklingError); __pyx_t_2 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 115, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_PicklingError); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 115, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_PicklingError, __pyx_t_1) < 0) __PYX_ERR(4, 115, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":117 * from pickle import PicklingError * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * from Queue import Queue * import contextlib2 as contextlib */ __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0); if (__pyx_t_3) { /* "llfuse.pyx":118 * * if PY_MAJOR_VERSION < 3: * from Queue import Queue # <<<<<<<<<<<<<< * import contextlib2 as contextlib * str_t = bytes */ __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 118, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_INCREF(__pyx_n_s_Queue); __Pyx_GIVEREF(__pyx_n_s_Queue); PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_Queue); __pyx_t_1 = __Pyx_Import(__pyx_n_s_Queue, __pyx_t_2, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 118, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_1, __pyx_n_s_Queue); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 118, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_Queue, __pyx_t_2) < 0) __PYX_ERR(4, 118, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":119 * if PY_MAJOR_VERSION < 3: * from Queue import Queue * import contextlib2 as contextlib # <<<<<<<<<<<<<< * str_t = bytes * else: */ __pyx_t_1 = __Pyx_Import(__pyx_n_s_contextlib2, 0, 0); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 119, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_contextlib, __pyx_t_1) < 0) __PYX_ERR(4, 119, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":120 * from Queue import Queue * import contextlib2 as contextlib * str_t = bytes # <<<<<<<<<<<<<< * else: * from queue import Queue */ if (PyDict_SetItem(__pyx_d, __pyx_n_s_str_t, ((PyObject *)(&PyBytes_Type))) < 0) __PYX_ERR(4, 120, __pyx_L1_error) /* "llfuse.pyx":117 * from pickle import PicklingError * * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<< * from Queue import Queue * import contextlib2 as contextlib */ goto __pyx_L2; } /* "llfuse.pyx":122 * str_t = bytes * else: * from queue import Queue # <<<<<<<<<<<<<< * str_t = str * import contextlib */ /*else*/ { __pyx_t_1 = PyList_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_n_s_Queue); __Pyx_GIVEREF(__pyx_n_s_Queue); PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_Queue); __pyx_t_2 = __Pyx_Import(__pyx_n_s_queue, __pyx_t_1, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_Queue); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 122, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_Queue, __pyx_t_1) < 0) __PYX_ERR(4, 122, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":123 * else: * from queue import Queue * str_t = str # <<<<<<<<<<<<<< * import contextlib * */ if (PyDict_SetItem(__pyx_d, __pyx_n_s_str_t, ((PyObject *)(&PyUnicode_Type))) < 0) __PYX_ERR(4, 123, __pyx_L1_error) /* "llfuse.pyx":124 * from queue import Queue * str_t = str * import contextlib # <<<<<<<<<<<<<< * * ################## */ __pyx_t_2 = __Pyx_Import(__pyx_n_s_contextlib, 0, 0); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 124, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_contextlib, __pyx_t_2) < 0) __PYX_ERR(4, 124, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } __pyx_L2:; /* "llfuse.pyx":130 * ################## * * log = logging.getLogger("llfuse") # <<<<<<<<<<<<<< * fse = sys.getfilesystemencoding() * */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_logging); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 130, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_getLogger); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 130, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_tuple__85, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 130, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; if (PyDict_SetItem(__pyx_d, __pyx_n_s_log, __pyx_t_2) < 0) __PYX_ERR(4, 130, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":131 * * log = logging.getLogger("llfuse") * fse = sys.getfilesystemencoding() # <<<<<<<<<<<<<< * * cdef object operations */ __pyx_t_1 = __Pyx_GetModuleGlobalName(__pyx_n_s_sys); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 131, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_getfilesystemencoding); if (unlikely(!__pyx_t_4)) __PYX_ERR(4, 131, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_1 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) { __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_4); if (likely(__pyx_t_1)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4); __Pyx_INCREF(__pyx_t_1); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_4, function); } } if (__pyx_t_1) { __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_1); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 131, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; } else { __pyx_t_2 = __Pyx_PyObject_CallNoArg(__pyx_t_4); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 131, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; if (PyDict_SetItem(__pyx_d, __pyx_n_s_fse, __pyx_t_2) < 0) __PYX_ERR(4, 131, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":135 * cdef object operations * cdef object mountpoint_b * cdef fuse_session* session = NULL # <<<<<<<<<<<<<< * cdef fuse_chan* channel = NULL * cdef fuse_lowlevel_ops fuse_ops */ __pyx_v_6llfuse_session = NULL; /* "llfuse.pyx":136 * cdef object mountpoint_b * cdef fuse_session* session = NULL * cdef fuse_chan* channel = NULL # <<<<<<<<<<<<<< * cdef fuse_lowlevel_ops fuse_ops * cdef object exc_info */ __pyx_v_6llfuse_channel = NULL; /* "llfuse.pyx":142 * cdef pthread_mutex_t exc_info_mutex * * init_lock() # <<<<<<<<<<<<<< * lock = Lock.__new__(Lock) * lock_released = NoLockManager.__new__(NoLockManager) */ init_lock(); /* "llfuse.pyx":143 * * init_lock() * lock = Lock.__new__(Lock) # <<<<<<<<<<<<<< * lock_released = NoLockManager.__new__(NoLockManager) * */ __pyx_t_2 = __pyx_tp_new_6llfuse_Lock(((PyTypeObject *)__pyx_ptype_6llfuse_Lock), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 143, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_lock, __pyx_t_2) < 0) __PYX_ERR(4, 143, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":144 * init_lock() * lock = Lock.__new__(Lock) * lock_released = NoLockManager.__new__(NoLockManager) # <<<<<<<<<<<<<< * * cdef object _notify_queue */ __pyx_t_2 = __pyx_tp_new_6llfuse_NoLockManager(((PyTypeObject *)__pyx_ptype_6llfuse_NoLockManager), __pyx_empty_tuple, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 144, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_lock_released, __pyx_t_2) < 0) __PYX_ERR(4, 144, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":147 * * cdef object _notify_queue * _notify_queue = Queue(maxsize=1000) # <<<<<<<<<<<<<< * * # Exported for access from Python code */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_Queue); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_t_4 = PyDict_New(); if (unlikely(!__pyx_t_4)) __PYX_ERR(4, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_maxsize, __pyx_int_1000) < 0) __PYX_ERR(4, 147, __pyx_L1_error) __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_empty_tuple, __pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 147, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_XGOTREF(__pyx_v_6llfuse__notify_queue); __Pyx_DECREF_SET(__pyx_v_6llfuse__notify_queue, __pyx_t_1); __Pyx_GIVEREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":152 * # (in the Cython source, we want ENOATTR to refer * # to the C constant, not a Python object) * ROOT_INODE = FUSE_ROOT_ID # <<<<<<<<<<<<<< * __version__ = LLFUSE_VERSION.decode('utf-8') * globals()['ENOATTR'] = ENOATTR */ __pyx_t_1 = __Pyx_PyInt_From_int(FUSE_ROOT_ID); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 152, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_ROOT_INODE, __pyx_t_1) < 0) __PYX_ERR(4, 152, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":153 * # to the C constant, not a Python object) * ROOT_INODE = FUSE_ROOT_ID * __version__ = LLFUSE_VERSION.decode('utf-8') # <<<<<<<<<<<<<< * globals()['ENOATTR'] = ENOATTR * */ __pyx_t_1 = __Pyx_decode_c_string(LLFUSE_VERSION, 0, strlen(LLFUSE_VERSION), NULL, NULL, PyUnicode_DecodeUTF8); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 153, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_version, __pyx_t_1) < 0) __PYX_ERR(4, 153, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "llfuse.pyx":154 * ROOT_INODE = FUSE_ROOT_ID * __version__ = LLFUSE_VERSION.decode('utf-8') * globals()['ENOATTR'] = ENOATTR # <<<<<<<<<<<<<< * * ####################### */ __pyx_t_1 = __Pyx_PyInt_From_int(ENOATTR); if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __pyx_t_4 = __Pyx_Globals(); if (unlikely(!__pyx_t_4)) __PYX_ERR(4, 154, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); if (unlikely(PyObject_SetItem(__pyx_t_4, __pyx_n_u_ENOATTR, __pyx_t_1) < 0)) __PYX_ERR(4, 154, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/operations.pxi":11 * ''' * * class Operations(object): # <<<<<<<<<<<<<< * ''' * This class defines the general and request handler methods that an */ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 11, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); __Pyx_INCREF(__pyx_builtin_object); __Pyx_GIVEREF(__pyx_builtin_object); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_builtin_object); __pyx_t_4 = __Pyx_CalculateMetaclass(NULL, __pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 11, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = __Pyx_Py3MetaclassPrepare(__pyx_t_4, __pyx_t_1, __pyx_n_s_Operations, __pyx_n_s_Operations, (PyObject *) NULL, __pyx_n_s_llfuse, __pyx_kp_s_This_class_defines_the_general); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 11, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); /* "src/operations.pxi":28 * ''' * * def init(self): # <<<<<<<<<<<<<< * '''Initialize operations * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_1init, 0, __pyx_n_s_Operations_init, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__87)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 28, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_init, __pyx_t_5) < 0) __PYX_ERR(0, 28, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":38 * pass * * def destroy(self): # <<<<<<<<<<<<<< * '''Clean up operations. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_3destroy, 0, __pyx_n_s_Operations_destroy, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__89)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 38, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_destroy, __pyx_t_5) < 0) __PYX_ERR(0, 38, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":50 * pass * * def lookup(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Look up a directory entry by name and get its attributes. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_5lookup, 0, __pyx_n_s_Operations_lookup, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__91)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 50, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_lookup, __pyx_t_5) < 0) __PYX_ERR(0, 50, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":73 * raise FUSEError(errno.ENOSYS) * * def forget(self, inode_list): # <<<<<<<<<<<<<< * '''Decrease lookup counts for inodes in *inode_list* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_7forget, 0, __pyx_n_s_Operations_forget, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__93)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_forget, __pyx_t_5) < 0) __PYX_ERR(0, 73, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":96 * pass * * def getattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get attributes for *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_9getattr, 0, __pyx_n_s_Operations_getattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__95)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 96, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_getattr, __pyx_t_5) < 0) __PYX_ERR(0, 96, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":109 * * * def setattr(self, inode, attr, fields, fh, ctx): # <<<<<<<<<<<<<< * '''Change attributes of *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_11setattr, 0, __pyx_n_s_Operations_setattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__97)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 109, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_setattr, __pyx_t_5) < 0) __PYX_ERR(0, 109, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":136 * raise FUSEError(errno.ENOSYS) * * def readlink(self, inode, ctx): # <<<<<<<<<<<<<< * '''Return target of symbolic link *inode*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_13readlink, 0, __pyx_n_s_Operations_readlink, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__99)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 136, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_readlink, __pyx_t_5) < 0) __PYX_ERR(0, 136, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":145 * * * def mknod(self, parent_inode, name, mode, rdev, ctx): # <<<<<<<<<<<<<< * '''Create (possibly special) file * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_15mknod, 0, __pyx_n_s_Operations_mknod, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__101)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 145, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_mknod, __pyx_t_5) < 0) __PYX_ERR(0, 145, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":163 * raise FUSEError(errno.ENOSYS) * * def mkdir(self, parent_inode, name, mode, ctx): # <<<<<<<<<<<<<< * '''Create a directory * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_17mkdir, 0, __pyx_n_s_Operations_mkdir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__103)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 163, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_mkdir, __pyx_t_5) < 0) __PYX_ERR(0, 163, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":179 * raise FUSEError(errno.ENOSYS) * * def unlink(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove a (possibly special) file * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_19unlink, 0, __pyx_n_s_Operations_unlink, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__105)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_unlink, __pyx_t_5) < 0) __PYX_ERR(0, 179, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":201 * raise FUSEError(errno.ENOSYS) * * def rmdir(self, parent_inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove directory *name* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_21rmdir, 0, __pyx_n_s_Operations_rmdir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__107)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 201, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_rmdir, __pyx_t_5) < 0) __PYX_ERR(0, 201, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":225 * raise FUSEError(errno.ENOSYS) * * def symlink(self, parent_inode, name, target, ctx): # <<<<<<<<<<<<<< * '''Create a symbolic link * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_23symlink, 0, __pyx_n_s_Operations_symlink, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__109)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 225, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_symlink, __pyx_t_5) < 0) __PYX_ERR(0, 225, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":241 * raise FUSEError(errno.ENOSYS) * * def rename(self, parent_inode_old, name_old, parent_inode_new, # <<<<<<<<<<<<<< * name_new, ctx): * '''Rename a directory entry. */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_25rename, 0, __pyx_n_s_Operations_rename, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__111)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 241, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_rename, __pyx_t_5) < 0) __PYX_ERR(0, 241, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":266 * raise FUSEError(errno.ENOSYS) * * def link(self, inode, new_parent_inode, new_name, ctx): # <<<<<<<<<<<<<< * '''Create directory entry *name* in *parent_inode* refering to *inode*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_27link, 0, __pyx_n_s_Operations_link, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__113)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 266, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_link, __pyx_t_5) < 0) __PYX_ERR(0, 266, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":280 * raise FUSEError(errno.ENOSYS) * * def open(self, inode, flags, ctx): # <<<<<<<<<<<<<< * '''Open a inode *inode* with *flags*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_29open, 0, __pyx_n_s_Operations_open, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__115)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 280, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_open, __pyx_t_5) < 0) __PYX_ERR(0, 280, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":296 * raise FUSEError(errno.ENOSYS) * * def read(self, fh, off, size): # <<<<<<<<<<<<<< * '''Read *size* bytes from *fh* at position *off* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_31read, 0, __pyx_n_s_Operations_read, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__117)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 296, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_read, __pyx_t_5) < 0) __PYX_ERR(0, 296, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":309 * raise FUSEError(errno.ENOSYS) * * def write(self, fh, off, buf): # <<<<<<<<<<<<<< * '''Write *buf* into *fh* at *off* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_33write, 0, __pyx_n_s_Operations_write, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__119)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 309, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_write, __pyx_t_5) < 0) __PYX_ERR(0, 309, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":323 * raise FUSEError(errno.ENOSYS) * * def flush(self, fh): # <<<<<<<<<<<<<< * '''Handle close() syscall. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_35flush, 0, __pyx_n_s_Operations_flush, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__121)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_flush, __pyx_t_5) < 0) __PYX_ERR(0, 323, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":336 * raise FUSEError(errno.ENOSYS) * * def release(self, fh): # <<<<<<<<<<<<<< * '''Release open file * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_37release, 0, __pyx_n_s_Operations_release, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__123)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 336, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_release, __pyx_t_5) < 0) __PYX_ERR(0, 336, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":354 * raise FUSEError(errno.ENOSYS) * * def fsync(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open file *fh* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_39fsync, 0, __pyx_n_s_Operations_fsync, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__125)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 354, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_fsync, __pyx_t_5) < 0) __PYX_ERR(0, 354, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":366 * raise FUSEError(errno.ENOSYS) * * def opendir(self, inode, ctx): # <<<<<<<<<<<<<< * '''Open the directory with inode *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_41opendir, 0, __pyx_n_s_Operations_opendir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__127)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_opendir, __pyx_t_5) < 0) __PYX_ERR(0, 366, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":379 * * * def readdir(self, fh, off): # <<<<<<<<<<<<<< * '''Read entries in open directory *fh*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_43readdir, 0, __pyx_n_s_Operations_readdir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__129)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 379, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_readdir, __pyx_t_5) < 0) __PYX_ERR(0, 379, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":403 * raise FUSEError(errno.ENOSYS) * * def releasedir(self, fh): # <<<<<<<<<<<<<< * '''Release open directory * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_45releasedir, 0, __pyx_n_s_Operations_releasedir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__131)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 403, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_releasedir, __pyx_t_5) < 0) __PYX_ERR(0, 403, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":413 * raise FUSEError(errno.ENOSYS) * * def fsyncdir(self, fh, datasync): # <<<<<<<<<<<<<< * '''Flush buffers for open directory *fh* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_47fsyncdir, 0, __pyx_n_s_Operations_fsyncdir, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__133)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_fsyncdir, __pyx_t_5) < 0) __PYX_ERR(0, 413, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":422 * raise FUSEError(errno.ENOSYS) * * def statfs(self, ctx): # <<<<<<<<<<<<<< * '''Get file system statistics * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_49statfs, 0, __pyx_n_s_Operations_statfs, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__135)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 422, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_statfs, __pyx_t_5) < 0) __PYX_ERR(0, 422, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":432 * raise FUSEError(errno.ENOSYS) * * def stacktrace(self): # <<<<<<<<<<<<<< * '''Asynchronous debugging * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_51stacktrace, 0, __pyx_n_s_Operations_stacktrace, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__137)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_stacktrace, __pyx_t_5) < 0) __PYX_ERR(0, 432, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":455 * log.error("\n".join(code)) * * def setxattr(self, inode, name, value, ctx): # <<<<<<<<<<<<<< * '''Set extended attribute *name* of *inode* to *value*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_53setxattr, 0, __pyx_n_s_Operations_setxattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__139)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 455, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_setxattr, __pyx_t_5) < 0) __PYX_ERR(0, 455, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":467 * raise FUSEError(errno.ENOSYS) * * def getxattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Return extended attribute *name* of *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_55getxattr, 0, __pyx_n_s_Operations_getxattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__141)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 467, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_getxattr, __pyx_t_5) < 0) __PYX_ERR(0, 467, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":479 * raise FUSEError(errno.ENOSYS) * * def listxattr(self, inode, ctx): # <<<<<<<<<<<<<< * '''Get list of extended attributes for *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_57listxattr, 0, __pyx_n_s_Operations_listxattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__143)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 479, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_listxattr, __pyx_t_5) < 0) __PYX_ERR(0, 479, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":490 * raise FUSEError(errno.ENOSYS) * * def removexattr(self, inode, name, ctx): # <<<<<<<<<<<<<< * '''Remove extended attribute *name* of *inode* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_59removexattr, 0, __pyx_n_s_Operations_removexattr, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__145)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 490, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_removexattr, __pyx_t_5) < 0) __PYX_ERR(0, 490, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":503 * * * def access(self, inode, mode, ctx): # <<<<<<<<<<<<<< * '''Check if requesting process has *mode* rights on *inode*. * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_61access, 0, __pyx_n_s_Operations_access, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__147)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 503, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_access, __pyx_t_5) < 0) __PYX_ERR(0, 503, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":519 * raise FUSEError(errno.ENOSYS) * * def create(self, parent_inode, name, mode, flags, ctx): # <<<<<<<<<<<<<< * '''Create a file with permissions *mode* and open it with *flags* * */ __pyx_t_5 = __Pyx_CyFunction_NewEx(&__pyx_mdef_6llfuse_10Operations_63create, 0, __pyx_n_s_Operations_create, NULL, __pyx_n_s_llfuse, __pyx_d, ((PyObject *)__pyx_codeobj__149)); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 519, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyObject_SetItem(__pyx_t_2, __pyx_n_s_create, __pyx_t_5) < 0) __PYX_ERR(0, 519, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; /* "src/operations.pxi":11 * ''' * * class Operations(object): # <<<<<<<<<<<<<< * ''' * This class defines the general and request handler methods that an */ __pyx_t_5 = __Pyx_Py3ClassCreate(__pyx_t_4, __pyx_n_s_Operations, __pyx_t_1, __pyx_t_2, NULL, 0, 0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 11, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_5); if (PyDict_SetItem(__pyx_d, __pyx_n_s_Operations, __pyx_t_5) < 0) __PYX_ERR(0, 11, __pyx_L1_error) __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0; __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/misc.pxi":258 * raise PicklingError("NoLockManager instances can't be pickled") * * def _notify_loop(): # <<<<<<<<<<<<<< * '''Read notifications from queue and send to FUSE kernel module''' * */ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_1_notify_loop, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 258, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_notify_loop, __pyx_t_1) < 0) __PYX_ERR(2, 258, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":14 * ''' * * def listdir(path): # <<<<<<<<<<<<<< * '''Like `os.listdir`, but releases the GIL. * */ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_3listdir, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 14, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_listdir, __pyx_t_1) < 0) __PYX_ERR(3, 14, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":66 * * * def setxattr(path, name, bytes value, namespace='user'): # <<<<<<<<<<<<<< * '''Set extended attribute * */ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_5setxattr, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 66, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_setxattr, __pyx_t_1) < 0) __PYX_ERR(3, 66, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":117 * * * def getxattr(path, name, size_t size_guess=128, namespace='user'): # <<<<<<<<<<<<<< * '''Get extended attribute * */ __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_7getxattr, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 117, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_1); if (PyDict_SetItem(__pyx_d, __pyx_n_s_getxattr, __pyx_t_1) < 0) __PYX_ERR(3, 117, __pyx_L1_error) __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; /* "src/fuse_api.pxi":216 * # page instead of copying them. * # * if os.uname()[0] == 'Darwin': # <<<<<<<<<<<<<< * default_options = frozenset(('big_writes', 'default_permissions', * 'no_splice_read', 'splice_write', 'splice_move')) */ __pyx_t_4 = __Pyx_GetModuleGlobalName(__pyx_n_s_os); if (unlikely(!__pyx_t_4)) __PYX_ERR(3, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_4); __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_uname); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; __pyx_t_4 = NULL; if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) { __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2); if (likely(__pyx_t_4)) { PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2); __Pyx_INCREF(__pyx_t_4); __Pyx_INCREF(function); __Pyx_DECREF_SET(__pyx_t_2, function); } } if (__pyx_t_4) { __pyx_t_1 = __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0; } else { __pyx_t_1 = __Pyx_PyObject_CallNoArg(__pyx_t_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 216, __pyx_L1_error) } __Pyx_GOTREF(__pyx_t_1); __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = __Pyx_GetItemInt(__pyx_t_1, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 216, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0; __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_t_2, __pyx_n_u_Darwin, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(3, 216, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; if (__pyx_t_3) { /* "src/fuse_api.pxi":217 * # * if os.uname()[0] == 'Darwin': * default_options = frozenset(('big_writes', 'default_permissions', # <<<<<<<<<<<<<< * 'no_splice_read', 'splice_write', 'splice_move')) * else: */ __pyx_t_2 = __Pyx_PyFrozenSet_New(__pyx_tuple__158); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 217, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_default_options, __pyx_t_2) < 0) __PYX_ERR(3, 217, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":216 * # page instead of copying them. * # * if os.uname()[0] == 'Darwin': # <<<<<<<<<<<<<< * default_options = frozenset(('big_writes', 'default_permissions', * 'no_splice_read', 'splice_write', 'splice_move')) */ goto __pyx_L3; } /* "src/fuse_api.pxi":220 * 'no_splice_read', 'splice_write', 'splice_move')) * else: * default_options = frozenset(('big_writes', 'nonempty', 'default_permissions', # <<<<<<<<<<<<<< * 'no_splice_read', 'splice_write', 'splice_move')) * */ /*else*/ { __pyx_t_2 = __Pyx_PyFrozenSet_New(__pyx_tuple__159); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 220, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_default_options, __pyx_t_2) < 0) __PYX_ERR(3, 220, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; } __pyx_L3:; /* "src/fuse_api.pxi":223 * 'no_splice_read', 'splice_write', 'splice_move')) * * def init(ops, mountpoint, options=default_options): # <<<<<<<<<<<<<< * '''Initialize and mount FUSE file system * */ __pyx_t_2 = __Pyx_GetModuleGlobalName(__pyx_n_s_default_options); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); __pyx_k__65 = __pyx_t_2; __Pyx_GIVEREF(__pyx_t_2); __pyx_t_2 = 0; __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_9init, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 223, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_init, __pyx_t_2) < 0) __PYX_ERR(3, 223, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":278 * pthread_mutex_init(&exc_info_mutex, NULL) * * def main(workers=None): # <<<<<<<<<<<<<< * '''Run FUSE main loop * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_11main, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 278, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_main_2, __pyx_t_2) < 0) __PYX_ERR(3, 278, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":491 * * * def close(unmount=True): # <<<<<<<<<<<<<< * '''Clean up and ensure filesystem is unmounted * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_13close, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 491, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_close, __pyx_t_2) < 0) __PYX_ERR(3, 491, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":543 * raise tmp[1].with_traceback(tmp[2]) * * def invalidate_inode(fuse_ino_t inode, attr_only=False): # <<<<<<<<<<<<<< * '''Invalidate cache for *inode* * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_15invalidate_inode, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 543, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_invalidate_inode, __pyx_t_2) < 0) __PYX_ERR(3, 543, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":559 * _notify_queue.put(req) * * def invalidate_entry(fuse_ino_t inode_p, bytes name): # <<<<<<<<<<<<<< * '''Invalidate directory entry * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_17invalidate_entry, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 559, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_invalidate_entry, __pyx_t_2) < 0) __PYX_ERR(3, 559, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":575 * _notify_queue.put(req) * * def get_ino_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bits available for inode numbers * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_19get_ino_t_bits, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 575, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_ino_t_bits, __pyx_t_2) < 0) __PYX_ERR(3, 575, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":583 * return min(sizeof(ino_t), sizeof(fuse_ino_t)) * 8 * * def get_off_t_bits(): # <<<<<<<<<<<<<< * '''Return number of bytes available for file offsets * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_21get_off_t_bits, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 583, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_off_t_bits, __pyx_t_2) < 0) __PYX_ERR(3, 583, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":591 * return sizeof(off_t) * 8 * * def notify_store(inode, offset, data): # <<<<<<<<<<<<<< * '''Store data in kernel page cache * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_23notify_store, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 591, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_notify_store, __pyx_t_2) < 0) __PYX_ERR(3, 591, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "src/fuse_api.pxi":628 * raise OSError(-ret, 'fuse_lowlevel_notify_store returned: ' + strerror(-ret)) * * def get_sup_groups(pid): # <<<<<<<<<<<<<< * '''Return supplementary group ids of *pid* * */ __pyx_t_2 = PyCFunction_NewEx(&__pyx_mdef_6llfuse_25get_sup_groups, NULL, __pyx_n_s_llfuse); if (unlikely(!__pyx_t_2)) __PYX_ERR(3, 628, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_sup_groups, __pyx_t_2) < 0) __PYX_ERR(3, 628, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /* "llfuse.pyx":1 * ''' # <<<<<<<<<<<<<< * llfuse.pxy * */ __pyx_t_2 = PyDict_New(); if (unlikely(!__pyx_t_2)) __PYX_ERR(4, 1, __pyx_L1_error) __Pyx_GOTREF(__pyx_t_2); if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_2) < 0) __PYX_ERR(4, 1, __pyx_L1_error) __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0; /*--- Wrapped vars code ---*/ goto __pyx_L0; __pyx_L1_error:; __Pyx_XDECREF(__pyx_t_1); __Pyx_XDECREF(__pyx_t_2); __Pyx_XDECREF(__pyx_t_4); __Pyx_XDECREF(__pyx_t_5); if (__pyx_m) { if (__pyx_d) { __Pyx_AddTraceback("init llfuse", __pyx_clineno, __pyx_lineno, __pyx_filename); } Py_DECREF(__pyx_m); __pyx_m = 0; } else if (!PyErr_Occurred()) { PyErr_SetString(PyExc_ImportError, "init llfuse"); } __pyx_L0:; __Pyx_RefNannyFinishContext(); #if PY_MAJOR_VERSION < 3 return; #else return __pyx_m; #endif } /* --- Runtime support code --- */ /* Refnanny */ #if CYTHON_REFNANNY static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) { PyObject *m = NULL, *p = NULL; void *r = NULL; m = PyImport_ImportModule((char *)modname); if (!m) goto end; p = PyObject_GetAttrString(m, (char *)"RefNannyAPI"); if (!p) goto end; r = PyLong_AsVoidPtr(p); end: Py_XDECREF(p); Py_XDECREF(m); return (__Pyx_RefNannyAPIStruct *)r; } #endif /* GetBuiltinName */ static PyObject *__Pyx_GetBuiltinName(PyObject *name) { PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name); if (unlikely(!result)) { PyErr_Format(PyExc_NameError, #if PY_MAJOR_VERSION >= 3 "name '%U' is not defined", name); #else "name '%.200s' is not defined", PyString_AS_STRING(name)); #endif } return result; } /* RaiseArgTupleInvalid */ static void __Pyx_RaiseArgtupleInvalid( const char* func_name, int exact, Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found) { Py_ssize_t num_expected; const char *more_or_less; if (num_found < num_min) { num_expected = num_min; more_or_less = "at least"; } else { num_expected = num_max; more_or_less = "at most"; } if (exact) { more_or_less = "exactly"; } PyErr_Format(PyExc_TypeError, "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)", func_name, more_or_less, num_expected, (num_expected == 1) ? "" : "s", num_found); } /* RaiseDoubleKeywords */ static void __Pyx_RaiseDoubleKeywordsError( const char* func_name, PyObject* kw_name) { PyErr_Format(PyExc_TypeError, #if PY_MAJOR_VERSION >= 3 "%s() got multiple values for keyword argument '%U'", func_name, kw_name); #else "%s() got multiple values for keyword argument '%s'", func_name, PyString_AsString(kw_name)); #endif } /* ParseKeywords */ static int __Pyx_ParseOptionalKeywords( PyObject *kwds, PyObject **argnames[], PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args, const char* function_name) { PyObject *key = 0, *value = 0; Py_ssize_t pos = 0; PyObject*** name; PyObject*** first_kw_arg = argnames + num_pos_args; while (PyDict_Next(kwds, &pos, &key, &value)) { name = first_kw_arg; while (*name && (**name != key)) name++; if (*name) { values[name-argnames] = value; continue; } name = first_kw_arg; #if PY_MAJOR_VERSION < 3 if (likely(PyString_CheckExact(key)) || likely(PyString_Check(key))) { while (*name) { if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key)) && _PyString_Eq(**name, key)) { values[name-argnames] = value; break; } name++; } if (*name) continue; else { PyObject*** argname = argnames; while (argname != first_kw_arg) { if ((**argname == key) || ( (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key)) && _PyString_Eq(**argname, key))) { goto arg_passed_twice; } argname++; } } } else #endif if (likely(PyUnicode_Check(key))) { while (*name) { int cmp = (**name == key) ? 0 : #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3 (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 : #endif PyUnicode_Compare(**name, key); if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad; if (cmp == 0) { values[name-argnames] = value; break; } name++; } if (*name) continue; else { PyObject*** argname = argnames; while (argname != first_kw_arg) { int cmp = (**argname == key) ? 0 : #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3 (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 : #endif PyUnicode_Compare(**argname, key); if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad; if (cmp == 0) goto arg_passed_twice; argname++; } } } else goto invalid_keyword_type; if (kwds2) { if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad; } else { goto invalid_keyword; } } return 0; arg_passed_twice: __Pyx_RaiseDoubleKeywordsError(function_name, key); goto bad; invalid_keyword_type: PyErr_Format(PyExc_TypeError, "%.200s() keywords must be strings", function_name); goto bad; invalid_keyword: PyErr_Format(PyExc_TypeError, #if PY_MAJOR_VERSION < 3 "%.200s() got an unexpected keyword argument '%.200s'", function_name, PyString_AsString(key)); #else "%s() got an unexpected keyword argument '%U'", function_name, key); #endif bad: return -1; } /* PyObjectCall */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) { PyObject *result; ternaryfunc call = func->ob_type->tp_call; if (unlikely(!call)) return PyObject_Call(func, arg, kw); if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object"))) return NULL; result = (*call)(func, arg, kw); Py_LeaveRecursiveCall(); if (unlikely(!result) && unlikely(!PyErr_Occurred())) { PyErr_SetString( PyExc_SystemError, "NULL result without error in PyObject_Call"); } return result; } #endif /* PyErrFetchRestore */ #if CYTHON_FAST_THREAD_STATE static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) { PyObject *tmp_type, *tmp_value, *tmp_tb; tmp_type = tstate->curexc_type; tmp_value = tstate->curexc_value; tmp_tb = tstate->curexc_traceback; tstate->curexc_type = type; tstate->curexc_value = value; tstate->curexc_traceback = tb; Py_XDECREF(tmp_type); Py_XDECREF(tmp_value); Py_XDECREF(tmp_tb); } static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) { *type = tstate->curexc_type; *value = tstate->curexc_value; *tb = tstate->curexc_traceback; tstate->curexc_type = 0; tstate->curexc_value = 0; tstate->curexc_traceback = 0; } #endif /* RaiseException */ #if PY_MAJOR_VERSION < 3 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, CYTHON_UNUSED PyObject *cause) { __Pyx_PyThreadState_declare Py_XINCREF(type); if (!value || value == Py_None) value = NULL; else Py_INCREF(value); if (!tb || tb == Py_None) tb = NULL; else { Py_INCREF(tb); if (!PyTraceBack_Check(tb)) { PyErr_SetString(PyExc_TypeError, "raise: arg 3 must be a traceback or None"); goto raise_error; } } if (PyType_Check(type)) { #if CYTHON_COMPILING_IN_PYPY if (!value) { Py_INCREF(Py_None); value = Py_None; } #endif PyErr_NormalizeException(&type, &value, &tb); } else { if (value) { PyErr_SetString(PyExc_TypeError, "instance exception may not have a separate value"); goto raise_error; } value = type; type = (PyObject*) Py_TYPE(type); Py_INCREF(type); if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) { PyErr_SetString(PyExc_TypeError, "raise: exception class must be a subclass of BaseException"); goto raise_error; } } __Pyx_PyThreadState_assign __Pyx_ErrRestore(type, value, tb); return; raise_error: Py_XDECREF(value); Py_XDECREF(type); Py_XDECREF(tb); return; } #else static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) { PyObject* owned_instance = NULL; if (tb == Py_None) { tb = 0; } else if (tb && !PyTraceBack_Check(tb)) { PyErr_SetString(PyExc_TypeError, "raise: arg 3 must be a traceback or None"); goto bad; } if (value == Py_None) value = 0; if (PyExceptionInstance_Check(type)) { if (value) { PyErr_SetString(PyExc_TypeError, "instance exception may not have a separate value"); goto bad; } value = type; type = (PyObject*) Py_TYPE(value); } else if (PyExceptionClass_Check(type)) { PyObject *instance_class = NULL; if (value && PyExceptionInstance_Check(value)) { instance_class = (PyObject*) Py_TYPE(value); if (instance_class != type) { int is_subclass = PyObject_IsSubclass(instance_class, type); if (!is_subclass) { instance_class = NULL; } else if (unlikely(is_subclass == -1)) { goto bad; } else { type = instance_class; } } } if (!instance_class) { PyObject *args; if (!value) args = PyTuple_New(0); else if (PyTuple_Check(value)) { Py_INCREF(value); args = value; } else args = PyTuple_Pack(1, value); if (!args) goto bad; owned_instance = PyObject_Call(type, args, NULL); Py_DECREF(args); if (!owned_instance) goto bad; value = owned_instance; if (!PyExceptionInstance_Check(value)) { PyErr_Format(PyExc_TypeError, "calling %R should have returned an instance of " "BaseException, not %R", type, Py_TYPE(value)); goto bad; } } } else { PyErr_SetString(PyExc_TypeError, "raise: exception class must be a subclass of BaseException"); goto bad; } #if PY_VERSION_HEX >= 0x03030000 if (cause) { #else if (cause && cause != Py_None) { #endif PyObject *fixed_cause; if (cause == Py_None) { fixed_cause = NULL; } else if (PyExceptionClass_Check(cause)) { fixed_cause = PyObject_CallObject(cause, NULL); if (fixed_cause == NULL) goto bad; } else if (PyExceptionInstance_Check(cause)) { fixed_cause = cause; Py_INCREF(fixed_cause); } else { PyErr_SetString(PyExc_TypeError, "exception causes must derive from " "BaseException"); goto bad; } PyException_SetCause(value, fixed_cause); } PyErr_SetObject(type, value); if (tb) { #if CYTHON_COMPILING_IN_PYPY PyObject *tmp_type, *tmp_value, *tmp_tb; PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb); Py_INCREF(tb); PyErr_Restore(tmp_type, tmp_value, tb); Py_XDECREF(tmp_tb); #else PyThreadState *tstate = PyThreadState_GET(); PyObject* tmp_tb = tstate->curexc_traceback; if (tb != tmp_tb) { Py_INCREF(tb); tstate->curexc_traceback = tb; Py_XDECREF(tmp_tb); } #endif } bad: Py_XDECREF(owned_instance); return; } #endif /* Import */ static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) { PyObject *empty_list = 0; PyObject *module = 0; PyObject *global_dict = 0; PyObject *empty_dict = 0; PyObject *list; #if PY_VERSION_HEX < 0x03030000 PyObject *py_import; py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import); if (!py_import) goto bad; #endif if (from_list) list = from_list; else { empty_list = PyList_New(0); if (!empty_list) goto bad; list = empty_list; } global_dict = PyModule_GetDict(__pyx_m); if (!global_dict) goto bad; empty_dict = PyDict_New(); if (!empty_dict) goto bad; { #if PY_MAJOR_VERSION >= 3 if (level == -1) { if (strchr(__Pyx_MODULE_NAME, '.')) { #if PY_VERSION_HEX < 0x03030000 PyObject *py_level = PyInt_FromLong(1); if (!py_level) goto bad; module = PyObject_CallFunctionObjArgs(py_import, name, global_dict, empty_dict, list, py_level, NULL); Py_DECREF(py_level); #else module = PyImport_ImportModuleLevelObject( name, global_dict, empty_dict, list, 1); #endif if (!module) { if (!PyErr_ExceptionMatches(PyExc_ImportError)) goto bad; PyErr_Clear(); } } level = 0; } #endif if (!module) { #if PY_VERSION_HEX < 0x03030000 PyObject *py_level = PyInt_FromLong(level); if (!py_level) goto bad; module = PyObject_CallFunctionObjArgs(py_import, name, global_dict, empty_dict, list, py_level, NULL); Py_DECREF(py_level); #else module = PyImport_ImportModuleLevelObject( name, global_dict, empty_dict, list, level); #endif } } bad: #if PY_VERSION_HEX < 0x03030000 Py_XDECREF(py_import); #endif Py_XDECREF(empty_list); Py_XDECREF(empty_dict); return module; } /* IterFinish */ static CYTHON_INLINE int __Pyx_IterFinish(void) { #if CYTHON_FAST_THREAD_STATE PyThreadState *tstate = PyThreadState_GET(); PyObject* exc_type = tstate->curexc_type; if (unlikely(exc_type)) { if (likely(exc_type == PyExc_StopIteration) || PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration)) { PyObject *exc_value, *exc_tb; exc_value = tstate->curexc_value; exc_tb = tstate->curexc_traceback; tstate->curexc_type = 0; tstate->curexc_value = 0; tstate->curexc_traceback = 0; Py_DECREF(exc_type); Py_XDECREF(exc_value); Py_XDECREF(exc_tb); return 0; } else { return -1; } } return 0; #else if (unlikely(PyErr_Occurred())) { if (likely(PyErr_ExceptionMatches(PyExc_StopIteration))) { PyErr_Clear(); return 0; } else { return -1; } } return 0; #endif } /* PyFunctionFastCall */ #if CYTHON_FAST_PYCALL #include "frameobject.h" static PyObject* __Pyx_PyFunction_FastCallNoKw(PyCodeObject *co, PyObject **args, Py_ssize_t na, PyObject *globals) { PyFrameObject *f; PyThreadState *tstate = PyThreadState_GET(); PyObject **fastlocals; Py_ssize_t i; PyObject *result; assert(globals != NULL); /* XXX Perhaps we should create a specialized PyFrame_New() that doesn't take locals, but does take builtins without sanity checking them. */ assert(tstate != NULL); f = PyFrame_New(tstate, co, globals, NULL); if (f == NULL) { return NULL; } fastlocals = f->f_localsplus; for (i = 0; i < na; i++) { Py_INCREF(*args); fastlocals[i] = *args++; } result = PyEval_EvalFrameEx(f,0); ++tstate->recursion_depth; Py_DECREF(f); --tstate->recursion_depth; return result; } #if 1 || PY_VERSION_HEX < 0x030600B1 static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, int nargs, PyObject *kwargs) { PyCodeObject *co = (PyCodeObject *)PyFunction_GET_CODE(func); PyObject *globals = PyFunction_GET_GLOBALS(func); PyObject *argdefs = PyFunction_GET_DEFAULTS(func); PyObject *closure; #if PY_MAJOR_VERSION >= 3 PyObject *kwdefs; #endif PyObject *kwtuple, **k; PyObject **d; Py_ssize_t nd; Py_ssize_t nk; PyObject *result; assert(kwargs == NULL || PyDict_Check(kwargs)); nk = kwargs ? PyDict_Size(kwargs) : 0; if (Py_EnterRecursiveCall((char*)" while calling a Python object")) { return NULL; } if ( #if PY_MAJOR_VERSION >= 3 co->co_kwonlyargcount == 0 && #endif likely(kwargs == NULL || nk == 0) && co->co_flags == (CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE)) { if (argdefs == NULL && co->co_argcount == nargs) { result = __Pyx_PyFunction_FastCallNoKw(co, args, nargs, globals); goto done; } else if (nargs == 0 && argdefs != NULL && co->co_argcount == Py_SIZE(argdefs)) { /* function called with no arguments, but all parameters have a default value: use default values as arguments .*/ args = &PyTuple_GET_ITEM(argdefs, 0); result =__Pyx_PyFunction_FastCallNoKw(co, args, Py_SIZE(argdefs), globals); goto done; } } if (kwargs != NULL) { Py_ssize_t pos, i; kwtuple = PyTuple_New(2 * nk); if (kwtuple == NULL) { result = NULL; goto done; } k = &PyTuple_GET_ITEM(kwtuple, 0); pos = i = 0; while (PyDict_Next(kwargs, &pos, &k[i], &k[i+1])) { Py_INCREF(k[i]); Py_INCREF(k[i+1]); i += 2; } nk = i / 2; } else { kwtuple = NULL; k = NULL; } closure = PyFunction_GET_CLOSURE(func); #if PY_MAJOR_VERSION >= 3 kwdefs = PyFunction_GET_KW_DEFAULTS(func); #endif if (argdefs != NULL) { d = &PyTuple_GET_ITEM(argdefs, 0); nd = Py_SIZE(argdefs); } else { d = NULL; nd = 0; } #if PY_MAJOR_VERSION >= 3 result = PyEval_EvalCodeEx((PyObject*)co, globals, (PyObject *)NULL, args, nargs, k, (int)nk, d, (int)nd, kwdefs, closure); #else result = PyEval_EvalCodeEx(co, globals, (PyObject *)NULL, args, nargs, k, (int)nk, d, (int)nd, closure); #endif Py_XDECREF(kwtuple); done: Py_LeaveRecursiveCall(); return result; } #endif // CPython < 3.6 #endif // CYTHON_FAST_PYCALL /* PyObjectCallMethO */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) { PyObject *self, *result; PyCFunction cfunc; cfunc = PyCFunction_GET_FUNCTION(func); self = PyCFunction_GET_SELF(func); if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object"))) return NULL; result = cfunc(self, arg); Py_LeaveRecursiveCall(); if (unlikely(!result) && unlikely(!PyErr_Occurred())) { PyErr_SetString( PyExc_SystemError, "NULL result without error in PyObject_Call"); } return result; } #endif /* PyObjectCallNoArg */ #if CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) { #if CYTHON_FAST_PYCALL if (PyFunction_Check(func)) { return __Pyx_PyFunction_FastCall(func, NULL, 0); } #endif #ifdef __Pyx_CyFunction_USED if (likely(PyCFunction_Check(func) || PyObject_TypeCheck(func, __pyx_CyFunctionType))) { #else if (likely(PyCFunction_Check(func))) { #endif if (likely(PyCFunction_GET_FLAGS(func) & METH_NOARGS)) { return __Pyx_PyObject_CallMethO(func, NULL); } } return __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL); } #endif /* PyCFunctionFastCall */ #if CYTHON_FAST_PYCCALL static CYTHON_INLINE PyObject * __Pyx_PyCFunction_FastCall(PyObject *func_obj, PyObject **args, Py_ssize_t nargs) { PyCFunctionObject *func = (PyCFunctionObject*)func_obj; PyCFunction meth = PyCFunction_GET_FUNCTION(func); PyObject *self = PyCFunction_GET_SELF(func); assert(PyCFunction_Check(func)); assert(METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST))); assert(nargs >= 0); assert(nargs == 0 || args != NULL); /* _PyCFunction_FastCallDict() must not be called with an exception set, because it may clear it (directly or indirectly) and so the caller loses its exception */ assert(!PyErr_Occurred()); return (*((__Pyx_PyCFunctionFast)meth)) (self, args, nargs, NULL); } #endif // CYTHON_FAST_PYCCALL /* PyObjectCallOneArg */ #if CYTHON_COMPILING_IN_CPYTHON static PyObject* __Pyx__PyObject_CallOneArg(PyObject *func, PyObject *arg) { PyObject *result; PyObject *args = PyTuple_New(1); if (unlikely(!args)) return NULL; Py_INCREF(arg); PyTuple_SET_ITEM(args, 0, arg); result = __Pyx_PyObject_Call(func, args, NULL); Py_DECREF(args); return result; } static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) { #if CYTHON_FAST_PYCALL if (PyFunction_Check(func)) { return __Pyx_PyFunction_FastCall(func, &arg, 1); } #endif #ifdef __Pyx_CyFunction_USED if (likely(PyCFunction_Check(func) || PyObject_TypeCheck(func, __pyx_CyFunctionType))) { #else if (likely(PyCFunction_Check(func))) { #endif if (likely(PyCFunction_GET_FLAGS(func) & METH_O)) { return __Pyx_PyObject_CallMethO(func, arg); #if CYTHON_FAST_PYCCALL } else if (PyCFunction_GET_FLAGS(func) & METH_FASTCALL) { return __Pyx_PyCFunction_FastCall(func, &arg, 1); #endif } } return __Pyx__PyObject_CallOneArg(func, arg); } #else static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) { PyObject *result; PyObject *args = PyTuple_Pack(1, arg); if (unlikely(!args)) return NULL; result = __Pyx_PyObject_Call(func, args, NULL); Py_DECREF(args); return result; } #endif /* PyObjectCallMethod0 */ static PyObject* __Pyx_PyObject_CallMethod0(PyObject* obj, PyObject* method_name) { PyObject *method, *result = NULL; method = __Pyx_PyObject_GetAttrStr(obj, method_name); if (unlikely(!method)) goto bad; #if CYTHON_UNPACK_METHODS if (likely(PyMethod_Check(method))) { PyObject *self = PyMethod_GET_SELF(method); if (likely(self)) { PyObject *function = PyMethod_GET_FUNCTION(method); result = __Pyx_PyObject_CallOneArg(function, self); Py_DECREF(method); return result; } } #endif result = __Pyx_PyObject_CallNoArg(method); Py_DECREF(method); bad: return result; } /* RaiseNeedMoreValuesToUnpack */ static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) { PyErr_Format(PyExc_ValueError, "need more than %" CYTHON_FORMAT_SSIZE_T "d value%.1s to unpack", index, (index == 1) ? "" : "s"); } /* RaiseTooManyValuesToUnpack */ static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) { PyErr_Format(PyExc_ValueError, "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T "d)", expected); } /* UnpackItemEndCheck */ static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) { if (unlikely(retval)) { Py_DECREF(retval); __Pyx_RaiseTooManyValuesError(expected); return -1; } else { return __Pyx_IterFinish(); } return 0; } /* RaiseNoneIterError */ static CYTHON_INLINE void __Pyx_RaiseNoneNotIterableError(void) { PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable"); } /* UnpackTupleError */ static void __Pyx_UnpackTupleError(PyObject *t, Py_ssize_t index) { if (t == Py_None) { __Pyx_RaiseNoneNotIterableError(); } else if (PyTuple_GET_SIZE(t) < index) { __Pyx_RaiseNeedMoreValuesError(PyTuple_GET_SIZE(t)); } else { __Pyx_RaiseTooManyValuesError(index); } } /* UnpackTuple2 */ static CYTHON_INLINE int __Pyx_unpack_tuple2(PyObject* tuple, PyObject** pvalue1, PyObject** pvalue2, int is_tuple, int has_known_size, int decref_tuple) { Py_ssize_t index; PyObject *value1 = NULL, *value2 = NULL, *iter = NULL; if (!is_tuple && unlikely(!PyTuple_Check(tuple))) { iternextfunc iternext; iter = PyObject_GetIter(tuple); if (unlikely(!iter)) goto bad; if (decref_tuple) { Py_DECREF(tuple); tuple = NULL; } iternext = Py_TYPE(iter)->tp_iternext; value1 = iternext(iter); if (unlikely(!value1)) { index = 0; goto unpacking_failed; } value2 = iternext(iter); if (unlikely(!value2)) { index = 1; goto unpacking_failed; } if (!has_known_size && unlikely(__Pyx_IternextUnpackEndCheck(iternext(iter), 2))) goto bad; Py_DECREF(iter); } else { if (!has_known_size && unlikely(PyTuple_GET_SIZE(tuple) != 2)) { __Pyx_UnpackTupleError(tuple, 2); goto bad; } #if CYTHON_COMPILING_IN_PYPY value1 = PySequence_ITEM(tuple, 0); if (unlikely(!value1)) goto bad; value2 = PySequence_ITEM(tuple, 1); if (unlikely(!value2)) goto bad; #else value1 = PyTuple_GET_ITEM(tuple, 0); value2 = PyTuple_GET_ITEM(tuple, 1); Py_INCREF(value1); Py_INCREF(value2); #endif if (decref_tuple) { Py_DECREF(tuple); } } *pvalue1 = value1; *pvalue2 = value2; return 0; unpacking_failed: if (!has_known_size && __Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index); bad: Py_XDECREF(iter); Py_XDECREF(value1); Py_XDECREF(value2); if (decref_tuple) { Py_XDECREF(tuple); } return -1; } /* dict_iter */ static CYTHON_INLINE PyObject* __Pyx_dict_iterator(PyObject* iterable, int is_dict, PyObject* method_name, Py_ssize_t* p_orig_length, int* p_source_is_dict) { is_dict = is_dict || likely(PyDict_CheckExact(iterable)); *p_source_is_dict = is_dict; #if !CYTHON_COMPILING_IN_PYPY if (is_dict) { *p_orig_length = PyDict_Size(iterable); Py_INCREF(iterable); return iterable; } #endif *p_orig_length = 0; if (method_name) { PyObject* iter; iterable = __Pyx_PyObject_CallMethod0(iterable, method_name); if (!iterable) return NULL; #if !CYTHON_COMPILING_IN_PYPY if (PyTuple_CheckExact(iterable) || PyList_CheckExact(iterable)) return iterable; #endif iter = PyObject_GetIter(iterable); Py_DECREF(iterable); return iter; } return PyObject_GetIter(iterable); } static CYTHON_INLINE int __Pyx_dict_iter_next( PyObject* iter_obj, CYTHON_NCP_UNUSED Py_ssize_t orig_length, CYTHON_NCP_UNUSED Py_ssize_t* ppos, PyObject** pkey, PyObject** pvalue, PyObject** pitem, int source_is_dict) { PyObject* next_item; #if !CYTHON_COMPILING_IN_PYPY if (source_is_dict) { PyObject *key, *value; if (unlikely(orig_length != PyDict_Size(iter_obj))) { PyErr_SetString(PyExc_RuntimeError, "dictionary changed size during iteration"); return -1; } if (unlikely(!PyDict_Next(iter_obj, ppos, &key, &value))) { return 0; } if (pitem) { PyObject* tuple = PyTuple_New(2); if (unlikely(!tuple)) { return -1; } Py_INCREF(key); Py_INCREF(value); PyTuple_SET_ITEM(tuple, 0, key); PyTuple_SET_ITEM(tuple, 1, value); *pitem = tuple; } else { if (pkey) { Py_INCREF(key); *pkey = key; } if (pvalue) { Py_INCREF(value); *pvalue = value; } } return 1; } else if (PyTuple_CheckExact(iter_obj)) { Py_ssize_t pos = *ppos; if (unlikely(pos >= PyTuple_GET_SIZE(iter_obj))) return 0; *ppos = pos + 1; next_item = PyTuple_GET_ITEM(iter_obj, pos); Py_INCREF(next_item); } else if (PyList_CheckExact(iter_obj)) { Py_ssize_t pos = *ppos; if (unlikely(pos >= PyList_GET_SIZE(iter_obj))) return 0; *ppos = pos + 1; next_item = PyList_GET_ITEM(iter_obj, pos); Py_INCREF(next_item); } else #endif { next_item = PyIter_Next(iter_obj); if (unlikely(!next_item)) { return __Pyx_IterFinish(); } } if (pitem) { *pitem = next_item; } else if (pkey && pvalue) { if (__Pyx_unpack_tuple2(next_item, pkey, pvalue, source_is_dict, source_is_dict, 1)) return -1; } else if (pkey) { *pkey = next_item; } else { *pvalue = next_item; } return 1; } /* GetModuleGlobalName */ static CYTHON_INLINE PyObject *__Pyx_GetModuleGlobalName(PyObject *name) { PyObject *result; #if !CYTHON_AVOID_BORROWED_REFS result = PyDict_GetItem(__pyx_d, name); if (likely(result)) { Py_INCREF(result); } else { #else result = PyObject_GetItem(__pyx_d, name); if (!result) { PyErr_Clear(); #endif result = __Pyx_GetBuiltinName(name); } return result; } /* SaveResetException */ #if CYTHON_FAST_THREAD_STATE static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) { *type = tstate->exc_type; *value = tstate->exc_value; *tb = tstate->exc_traceback; Py_XINCREF(*type); Py_XINCREF(*value); Py_XINCREF(*tb); } static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) { PyObject *tmp_type, *tmp_value, *tmp_tb; tmp_type = tstate->exc_type; tmp_value = tstate->exc_value; tmp_tb = tstate->exc_traceback; tstate->exc_type = type; tstate->exc_value = value; tstate->exc_traceback = tb; Py_XDECREF(tmp_type); Py_XDECREF(tmp_value); Py_XDECREF(tmp_tb); } #endif /* GetException */ #if CYTHON_FAST_THREAD_STATE static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) { #else static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb) { #endif PyObject *local_type, *local_value, *local_tb; #if CYTHON_FAST_THREAD_STATE PyObject *tmp_type, *tmp_value, *tmp_tb; local_type = tstate->curexc_type; local_value = tstate->curexc_value; local_tb = tstate->curexc_traceback; tstate->curexc_type = 0; tstate->curexc_value = 0; tstate->curexc_traceback = 0; #else PyErr_Fetch(&local_type, &local_value, &local_tb); #endif PyErr_NormalizeException(&local_type, &local_value, &local_tb); #if CYTHON_FAST_THREAD_STATE if (unlikely(tstate->curexc_type)) #else if (unlikely(PyErr_Occurred())) #endif goto bad; #if PY_MAJOR_VERSION >= 3 if (local_tb) { if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0)) goto bad; } #endif Py_XINCREF(local_tb); Py_XINCREF(local_type); Py_XINCREF(local_value); *type = local_type; *value = local_value; *tb = local_tb; #if CYTHON_FAST_THREAD_STATE tmp_type = tstate->exc_type; tmp_value = tstate->exc_value; tmp_tb = tstate->exc_traceback; tstate->exc_type = local_type; tstate->exc_value = local_value; tstate->exc_traceback = local_tb; Py_XDECREF(tmp_type); Py_XDECREF(tmp_value); Py_XDECREF(tmp_tb); #else PyErr_SetExcInfo(local_type, local_value, local_tb); #endif return 0; bad: *type = 0; *value = 0; *tb = 0; Py_XDECREF(local_type); Py_XDECREF(local_value); Py_XDECREF(local_tb); return -1; } /* WriteUnraisableException */ static void __Pyx_WriteUnraisable(const char *name, CYTHON_UNUSED int clineno, CYTHON_UNUSED int lineno, CYTHON_UNUSED const char *filename, int full_traceback, CYTHON_UNUSED int nogil) { PyObject *old_exc, *old_val, *old_tb; PyObject *ctx; __Pyx_PyThreadState_declare #ifdef WITH_THREAD PyGILState_STATE state; if (nogil) state = PyGILState_Ensure(); #ifdef _MSC_VER else state = (PyGILState_STATE)-1; #endif #endif __Pyx_PyThreadState_assign __Pyx_ErrFetch(&old_exc, &old_val, &old_tb); if (full_traceback) { Py_XINCREF(old_exc); Py_XINCREF(old_val); Py_XINCREF(old_tb); __Pyx_ErrRestore(old_exc, old_val, old_tb); PyErr_PrintEx(1); } #if PY_MAJOR_VERSION < 3 ctx = PyString_FromString(name); #else ctx = PyUnicode_FromString(name); #endif __Pyx_ErrRestore(old_exc, old_val, old_tb); if (!ctx) { PyErr_WriteUnraisable(Py_None); } else { PyErr_WriteUnraisable(ctx); Py_DECREF(ctx); } #ifdef WITH_THREAD if (nogil) PyGILState_Release(state); #endif } /* ExtTypeTest */ static CYTHON_INLINE int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type) { if (unlikely(!type)) { PyErr_SetString(PyExc_SystemError, "Missing type object"); return 0; } if (likely(PyObject_TypeCheck(obj, type))) return 1; PyErr_Format(PyExc_TypeError, "Cannot convert %.200s to %.200s", Py_TYPE(obj)->tp_name, type->tp_name); return 0; } /* None */ static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname) { PyErr_Format(PyExc_UnboundLocalError, "local variable '%s' referenced before assignment", varname); } /* PyErrExceptionMatches */ #if CYTHON_FAST_THREAD_STATE static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) { PyObject *exc_type = tstate->curexc_type; if (exc_type == err) return 1; if (unlikely(!exc_type)) return 0; return PyErr_GivenExceptionMatches(exc_type, err); } #endif /* SwapException */ #if CYTHON_FAST_THREAD_STATE static CYTHON_INLINE void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) { PyObject *tmp_type, *tmp_value, *tmp_tb; tmp_type = tstate->exc_type; tmp_value = tstate->exc_value; tmp_tb = tstate->exc_traceback; tstate->exc_type = *type; tstate->exc_value = *value; tstate->exc_traceback = *tb; *type = tmp_type; *value = tmp_value; *tb = tmp_tb; } #else static CYTHON_INLINE void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb) { PyObject *tmp_type, *tmp_value, *tmp_tb; PyErr_GetExcInfo(&tmp_type, &tmp_value, &tmp_tb); PyErr_SetExcInfo(*type, *value, *tb); *type = tmp_type; *value = tmp_value; *tb = tmp_tb; } #endif /* StringJoin */ #if !CYTHON_COMPILING_IN_CPYTHON static CYTHON_INLINE PyObject* __Pyx_PyBytes_Join(PyObject* sep, PyObject* values) { return PyObject_CallMethodObjArgs(sep, __pyx_n_s_join, values, NULL); } #endif /* GetItemInt */ static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) { PyObject *r; if (!j) return NULL; r = PyObject_GetItem(o, j); Py_DECREF(j); return r; } static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i, CYTHON_NCP_UNUSED int wraparound, CYTHON_NCP_UNUSED int boundscheck) { #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (wraparound & unlikely(i < 0)) i += PyList_GET_SIZE(o); if ((!boundscheck) || likely((0 <= i) & (i < PyList_GET_SIZE(o)))) { PyObject *r = PyList_GET_ITEM(o, i); Py_INCREF(r); return r; } return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i)); #else return PySequence_GetItem(o, i); #endif } static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i, CYTHON_NCP_UNUSED int wraparound, CYTHON_NCP_UNUSED int boundscheck) { #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS if (wraparound & unlikely(i < 0)) i += PyTuple_GET_SIZE(o); if ((!boundscheck) || likely((0 <= i) & (i < PyTuple_GET_SIZE(o)))) { PyObject *r = PyTuple_GET_ITEM(o, i); Py_INCREF(r); return r; } return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i)); #else return PySequence_GetItem(o, i); #endif } static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list, CYTHON_NCP_UNUSED int wraparound, CYTHON_NCP_UNUSED int boundscheck) { #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS if (is_list || PyList_CheckExact(o)) { Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o); if ((!boundscheck) || (likely((n >= 0) & (n < PyList_GET_SIZE(o))))) { PyObject *r = PyList_GET_ITEM(o, n); Py_INCREF(r); return r; } } else if (PyTuple_CheckExact(o)) { Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o); if ((!boundscheck) || likely((n >= 0) & (n < PyTuple_GET_SIZE(o)))) { PyObject *r = PyTuple_GET_ITEM(o, n); Py_INCREF(r); return r; } } else { PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence; if (likely(m && m->sq_item)) { if (wraparound && unlikely(i < 0) && likely(m->sq_length)) { Py_ssize_t l = m->sq_length(o); if (likely(l >= 0)) { i += l; } else { if (!PyErr_ExceptionMatches(PyExc_OverflowError)) return NULL; PyErr_Clear(); } } return m->sq_item(o, i); } } #else if (is_list || PySequence_Check(o)) { return PySequence_GetItem(o, i); } #endif return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i)); } /* KeywordStringCheck */ static CYTHON_INLINE int __Pyx_CheckKeywordStrings( PyObject *kwdict, const char* function_name, int kw_allowed) { PyObject* key = 0; Py_ssize_t pos = 0; #if CYTHON_COMPILING_IN_PYPY if (!kw_allowed && PyDict_Next(kwdict, &pos, &key, 0)) goto invalid_keyword; return 1; #else while (PyDict_Next(kwdict, &pos, &key, 0)) { #if PY_MAJOR_VERSION < 3 if (unlikely(!PyString_CheckExact(key)) && unlikely(!PyString_Check(key))) #endif if (unlikely(!PyUnicode_Check(key))) goto invalid_keyword_type; } if ((!kw_allowed) && unlikely(key)) goto invalid_keyword; return 1; invalid_keyword_type: PyErr_Format(PyExc_TypeError, "%.200s() keywords must be strings", function_name); return 0; #endif invalid_keyword: PyErr_Format(PyExc_TypeError, #if PY_MAJOR_VERSION < 3 "%.200s() got an unexpected keyword argument '%.200s'", function_name, PyString_AsString(key)); #else "%s() got an unexpected keyword argument '%U'", function_name, key); #endif return 0; } /* PyIntBinop */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_TrueDivideObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED int inplace) { #if PY_MAJOR_VERSION < 3 if (likely(PyInt_CheckExact(op1))) { const long b = intval; long a = PyInt_AS_LONG(op1); if (8 * sizeof(long) <= 53 || likely(labs(a) <= (1L << 53))) { return PyFloat_FromDouble((double)a / (double)b); } return PyInt_Type.tp_as_number->nb_true_divide(op1, op2); } #endif #if CYTHON_USE_PYLONG_INTERNALS if (likely(PyLong_CheckExact(op1))) { const long b = intval; long a, x; const digit* digits = ((PyLongObject*)op1)->ob_digit; const Py_ssize_t size = Py_SIZE(op1); if (likely(__Pyx_sst_abs(size) <= 1)) { a = likely(size) ? digits[0] : 0; if (size == -1) a = -a; } else { switch (size) { case -2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT && 1 * PyLong_SHIFT < 53) { a = -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT && 1 * PyLong_SHIFT < 53) { a = (long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case -3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT && 2 * PyLong_SHIFT < 53) { a = -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT && 2 * PyLong_SHIFT < 53) { a = (long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case -4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT && 3 * PyLong_SHIFT < 53) { a = -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT && 3 * PyLong_SHIFT < 53) { a = (long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } default: return PyLong_Type.tp_as_number->nb_true_divide(op1, op2); } } if ((8 * sizeof(long) <= 53 || likely(labs(a) <= (1L << 53))) || __Pyx_sst_abs(size) <= 52 / PyLong_SHIFT) { return PyFloat_FromDouble((double)a / (double)b); } return PyLong_Type.tp_as_number->nb_true_divide(op1, op2); return PyLong_FromLong(x); } #endif if (PyFloat_CheckExact(op1)) { const long b = intval; double a = PyFloat_AS_DOUBLE(op1); double result; PyFPE_START_PROTECT("divide", return NULL) result = ((double)a) / (double)b; PyFPE_END_PROTECT(result) return PyFloat_FromDouble(result); } return (inplace ? PyNumber_InPlaceTrueDivide : PyNumber_TrueDivide)(op1, op2); } #endif /* PyIntBinop */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_RemainderObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED int inplace) { #if PY_MAJOR_VERSION < 3 if (likely(PyInt_CheckExact(op1))) { const long b = intval; long x; long a = PyInt_AS_LONG(op1); x = a % b; x += ((x != 0) & ((x ^ b) < 0)) * b; return PyInt_FromLong(x); } #endif #if CYTHON_USE_PYLONG_INTERNALS if (likely(PyLong_CheckExact(op1))) { const long b = intval; long a, x; #ifdef HAVE_LONG_LONG const PY_LONG_LONG llb = intval; PY_LONG_LONG lla, llx; #endif const digit* digits = ((PyLongObject*)op1)->ob_digit; const Py_ssize_t size = Py_SIZE(op1); if (likely(__Pyx_sst_abs(size) <= 1)) { a = likely(size) ? digits[0] : 0; if (size == -1) a = -a; } else { switch (size) { case -2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { a = -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) { lla = -(PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } case 2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { a = (long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) { lla = (PY_LONG_LONG) (((((unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } case -3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { a = -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) { lla = -(PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } case 3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { a = (long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) { lla = (PY_LONG_LONG) (((((((unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } case -4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { a = -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) { lla = -(PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } case 4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { a = (long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; #ifdef HAVE_LONG_LONG } else if (8 * sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) { lla = (PY_LONG_LONG) (((((((((unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (unsigned PY_LONG_LONG)digits[0])); goto long_long; #endif } default: return PyLong_Type.tp_as_number->nb_remainder(op1, op2); } } x = a % b; x += ((x != 0) & ((x ^ b) < 0)) * b; return PyLong_FromLong(x); #ifdef HAVE_LONG_LONG long_long: llx = lla % llb; llx += ((llx != 0) & ((llx ^ llb) < 0)) * llb; return PyLong_FromLongLong(llx); #endif } #endif return (inplace ? PyNumber_InPlaceRemainder : PyNumber_Remainder)(op1, op2); } #endif /* GetAttr */ static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *o, PyObject *n) { #if CYTHON_COMPILING_IN_CPYTHON #if PY_MAJOR_VERSION >= 3 if (likely(PyUnicode_Check(n))) #else if (likely(PyString_Check(n))) #endif return __Pyx_PyObject_GetAttrStr(o, n); #endif return PyObject_GetAttr(o, n); } /* ArgTypeTest */ static void __Pyx_RaiseArgumentTypeInvalid(const char* name, PyObject *obj, PyTypeObject *type) { PyErr_Format(PyExc_TypeError, "Argument '%.200s' has incorrect type (expected %.200s, got %.200s)", name, type->tp_name, Py_TYPE(obj)->tp_name); } static CYTHON_INLINE int __Pyx_ArgTypeTest(PyObject *obj, PyTypeObject *type, int none_allowed, const char *name, int exact) { if (unlikely(!type)) { PyErr_SetString(PyExc_SystemError, "Missing type object"); return 0; } if (none_allowed && obj == Py_None) return 1; else if (exact) { if (likely(Py_TYPE(obj) == type)) return 1; #if PY_MAJOR_VERSION == 2 else if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj))) return 1; #endif } else { if (likely(PyObject_TypeCheck(obj, type))) return 1; } __Pyx_RaiseArgumentTypeInvalid(name, obj, type); return 0; } /* BytesEquals */ static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals) { #if CYTHON_COMPILING_IN_PYPY return PyObject_RichCompareBool(s1, s2, equals); #else if (s1 == s2) { return (equals == Py_EQ); } else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) { const char *ps1, *ps2; Py_ssize_t length = PyBytes_GET_SIZE(s1); if (length != PyBytes_GET_SIZE(s2)) return (equals == Py_NE); ps1 = PyBytes_AS_STRING(s1); ps2 = PyBytes_AS_STRING(s2); if (ps1[0] != ps2[0]) { return (equals == Py_NE); } else if (length == 1) { return (equals == Py_EQ); } else { int result = memcmp(ps1, ps2, (size_t)length); return (equals == Py_EQ) ? (result == 0) : (result != 0); } } else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) { return (equals == Py_NE); } else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) { return (equals == Py_NE); } else { int result; PyObject* py_result = PyObject_RichCompare(s1, s2, equals); if (!py_result) return -1; result = __Pyx_PyObject_IsTrue(py_result); Py_DECREF(py_result); return result; } #endif } /* UnicodeEquals */ static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) { #if CYTHON_COMPILING_IN_PYPY return PyObject_RichCompareBool(s1, s2, equals); #else #if PY_MAJOR_VERSION < 3 PyObject* owned_ref = NULL; #endif int s1_is_unicode, s2_is_unicode; if (s1 == s2) { goto return_eq; } s1_is_unicode = PyUnicode_CheckExact(s1); s2_is_unicode = PyUnicode_CheckExact(s2); #if PY_MAJOR_VERSION < 3 if ((s1_is_unicode & (!s2_is_unicode)) && PyString_CheckExact(s2)) { owned_ref = PyUnicode_FromObject(s2); if (unlikely(!owned_ref)) return -1; s2 = owned_ref; s2_is_unicode = 1; } else if ((s2_is_unicode & (!s1_is_unicode)) && PyString_CheckExact(s1)) { owned_ref = PyUnicode_FromObject(s1); if (unlikely(!owned_ref)) return -1; s1 = owned_ref; s1_is_unicode = 1; } else if (((!s2_is_unicode) & (!s1_is_unicode))) { return __Pyx_PyBytes_Equals(s1, s2, equals); } #endif if (s1_is_unicode & s2_is_unicode) { Py_ssize_t length; int kind; void *data1, *data2; if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0)) return -1; length = __Pyx_PyUnicode_GET_LENGTH(s1); if (length != __Pyx_PyUnicode_GET_LENGTH(s2)) { goto return_ne; } kind = __Pyx_PyUnicode_KIND(s1); if (kind != __Pyx_PyUnicode_KIND(s2)) { goto return_ne; } data1 = __Pyx_PyUnicode_DATA(s1); data2 = __Pyx_PyUnicode_DATA(s2); if (__Pyx_PyUnicode_READ(kind, data1, 0) != __Pyx_PyUnicode_READ(kind, data2, 0)) { goto return_ne; } else if (length == 1) { goto return_eq; } else { int result = memcmp(data1, data2, (size_t)(length * kind)); #if PY_MAJOR_VERSION < 3 Py_XDECREF(owned_ref); #endif return (equals == Py_EQ) ? (result == 0) : (result != 0); } } else if ((s1 == Py_None) & s2_is_unicode) { goto return_ne; } else if ((s2 == Py_None) & s1_is_unicode) { goto return_ne; } else { int result; PyObject* py_result = PyObject_RichCompare(s1, s2, equals); if (!py_result) return -1; result = __Pyx_PyObject_IsTrue(py_result); Py_DECREF(py_result); return result; } return_eq: #if PY_MAJOR_VERSION < 3 Py_XDECREF(owned_ref); #endif return (equals == Py_EQ); return_ne: #if PY_MAJOR_VERSION < 3 Py_XDECREF(owned_ref); #endif return (equals == Py_NE); #endif } /* PyIntBinop */ #if !CYTHON_COMPILING_IN_PYPY static PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED long intval, CYTHON_UNUSED int inplace) { if (op1 == op2) { Py_RETURN_TRUE; } #if PY_MAJOR_VERSION < 3 if (likely(PyInt_CheckExact(op1))) { const long b = intval; long a = PyInt_AS_LONG(op1); if (a == b) { Py_RETURN_TRUE; } else { Py_RETURN_FALSE; } } #endif #if CYTHON_USE_PYLONG_INTERNALS if (likely(PyLong_CheckExact(op1))) { const long b = intval; long a; const digit* digits = ((PyLongObject*)op1)->ob_digit; const Py_ssize_t size = Py_SIZE(op1); if (likely(__Pyx_sst_abs(size) <= 1)) { a = likely(size) ? digits[0] : 0; if (size == -1) a = -a; } else { switch (size) { case -2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { a = -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 2: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { a = (long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case -3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { a = -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 3: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { a = (long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case -4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { a = -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } case 4: if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { a = (long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); break; } #if PyLong_SHIFT < 30 && PyLong_SHIFT != 15 default: return PyLong_Type.tp_richcompare(op1, op2, Py_EQ); #else default: Py_RETURN_FALSE; #endif } } if (a == b) { Py_RETURN_TRUE; } else { Py_RETURN_FALSE; } } #endif if (PyFloat_CheckExact(op1)) { const long b = intval; double a = PyFloat_AS_DOUBLE(op1); if ((double)a == (double)b) { Py_RETURN_TRUE; } else { Py_RETURN_FALSE; } } return PyObject_RichCompare(op1, op2, Py_EQ); } #endif /* FetchCommonType */ static PyTypeObject* __Pyx_FetchCommonType(PyTypeObject* type) { PyObject* fake_module; PyTypeObject* cached_type = NULL; fake_module = PyImport_AddModule((char*) "_cython_" CYTHON_ABI); if (!fake_module) return NULL; Py_INCREF(fake_module); cached_type = (PyTypeObject*) PyObject_GetAttrString(fake_module, type->tp_name); if (cached_type) { if (!PyType_Check((PyObject*)cached_type)) { PyErr_Format(PyExc_TypeError, "Shared Cython type %.200s is not a type object", type->tp_name); goto bad; } if (cached_type->tp_basicsize != type->tp_basicsize) { PyErr_Format(PyExc_TypeError, "Shared Cython type %.200s has the wrong size, try recompiling", type->tp_name); goto bad; } } else { if (!PyErr_ExceptionMatches(PyExc_AttributeError)) goto bad; PyErr_Clear(); if (PyType_Ready(type) < 0) goto bad; if (PyObject_SetAttrString(fake_module, type->tp_name, (PyObject*) type) < 0) goto bad; Py_INCREF(type); cached_type = type; } done: Py_DECREF(fake_module); return cached_type; bad: Py_XDECREF(cached_type); cached_type = NULL; goto done; } /* CythonFunction */ static PyObject * __Pyx_CyFunction_get_doc(__pyx_CyFunctionObject *op, CYTHON_UNUSED void *closure) { if (unlikely(op->func_doc == NULL)) { if (op->func.m_ml->ml_doc) { #if PY_MAJOR_VERSION >= 3 op->func_doc = PyUnicode_FromString(op->func.m_ml->ml_doc); #else op->func_doc = PyString_FromString(op->func.m_ml->ml_doc); #endif if (unlikely(op->func_doc == NULL)) return NULL; } else { Py_INCREF(Py_None); return Py_None; } } Py_INCREF(op->func_doc); return op->func_doc; } static int __Pyx_CyFunction_set_doc(__pyx_CyFunctionObject *op, PyObject *value) { PyObject *tmp = op->func_doc; if (value == NULL) { value = Py_None; } Py_INCREF(value); op->func_doc = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_name(__pyx_CyFunctionObject *op) { if (unlikely(op->func_name == NULL)) { #if PY_MAJOR_VERSION >= 3 op->func_name = PyUnicode_InternFromString(op->func.m_ml->ml_name); #else op->func_name = PyString_InternFromString(op->func.m_ml->ml_name); #endif if (unlikely(op->func_name == NULL)) return NULL; } Py_INCREF(op->func_name); return op->func_name; } static int __Pyx_CyFunction_set_name(__pyx_CyFunctionObject *op, PyObject *value) { PyObject *tmp; #if PY_MAJOR_VERSION >= 3 if (unlikely(value == NULL || !PyUnicode_Check(value))) { #else if (unlikely(value == NULL || !PyString_Check(value))) { #endif PyErr_SetString(PyExc_TypeError, "__name__ must be set to a string object"); return -1; } tmp = op->func_name; Py_INCREF(value); op->func_name = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_qualname(__pyx_CyFunctionObject *op) { Py_INCREF(op->func_qualname); return op->func_qualname; } static int __Pyx_CyFunction_set_qualname(__pyx_CyFunctionObject *op, PyObject *value) { PyObject *tmp; #if PY_MAJOR_VERSION >= 3 if (unlikely(value == NULL || !PyUnicode_Check(value))) { #else if (unlikely(value == NULL || !PyString_Check(value))) { #endif PyErr_SetString(PyExc_TypeError, "__qualname__ must be set to a string object"); return -1; } tmp = op->func_qualname; Py_INCREF(value); op->func_qualname = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_self(__pyx_CyFunctionObject *m, CYTHON_UNUSED void *closure) { PyObject *self; self = m->func_closure; if (self == NULL) self = Py_None; Py_INCREF(self); return self; } static PyObject * __Pyx_CyFunction_get_dict(__pyx_CyFunctionObject *op) { if (unlikely(op->func_dict == NULL)) { op->func_dict = PyDict_New(); if (unlikely(op->func_dict == NULL)) return NULL; } Py_INCREF(op->func_dict); return op->func_dict; } static int __Pyx_CyFunction_set_dict(__pyx_CyFunctionObject *op, PyObject *value) { PyObject *tmp; if (unlikely(value == NULL)) { PyErr_SetString(PyExc_TypeError, "function's dictionary may not be deleted"); return -1; } if (unlikely(!PyDict_Check(value))) { PyErr_SetString(PyExc_TypeError, "setting function's dictionary to a non-dict"); return -1; } tmp = op->func_dict; Py_INCREF(value); op->func_dict = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_globals(__pyx_CyFunctionObject *op) { Py_INCREF(op->func_globals); return op->func_globals; } static PyObject * __Pyx_CyFunction_get_closure(CYTHON_UNUSED __pyx_CyFunctionObject *op) { Py_INCREF(Py_None); return Py_None; } static PyObject * __Pyx_CyFunction_get_code(__pyx_CyFunctionObject *op) { PyObject* result = (op->func_code) ? op->func_code : Py_None; Py_INCREF(result); return result; } static int __Pyx_CyFunction_init_defaults(__pyx_CyFunctionObject *op) { int result = 0; PyObject *res = op->defaults_getter((PyObject *) op); if (unlikely(!res)) return -1; #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS op->defaults_tuple = PyTuple_GET_ITEM(res, 0); Py_INCREF(op->defaults_tuple); op->defaults_kwdict = PyTuple_GET_ITEM(res, 1); Py_INCREF(op->defaults_kwdict); #else op->defaults_tuple = PySequence_ITEM(res, 0); if (unlikely(!op->defaults_tuple)) result = -1; else { op->defaults_kwdict = PySequence_ITEM(res, 1); if (unlikely(!op->defaults_kwdict)) result = -1; } #endif Py_DECREF(res); return result; } static int __Pyx_CyFunction_set_defaults(__pyx_CyFunctionObject *op, PyObject* value) { PyObject* tmp; if (!value) { value = Py_None; } else if (value != Py_None && !PyTuple_Check(value)) { PyErr_SetString(PyExc_TypeError, "__defaults__ must be set to a tuple object"); return -1; } Py_INCREF(value); tmp = op->defaults_tuple; op->defaults_tuple = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_defaults(__pyx_CyFunctionObject *op) { PyObject* result = op->defaults_tuple; if (unlikely(!result)) { if (op->defaults_getter) { if (__Pyx_CyFunction_init_defaults(op) < 0) return NULL; result = op->defaults_tuple; } else { result = Py_None; } } Py_INCREF(result); return result; } static int __Pyx_CyFunction_set_kwdefaults(__pyx_CyFunctionObject *op, PyObject* value) { PyObject* tmp; if (!value) { value = Py_None; } else if (value != Py_None && !PyDict_Check(value)) { PyErr_SetString(PyExc_TypeError, "__kwdefaults__ must be set to a dict object"); return -1; } Py_INCREF(value); tmp = op->defaults_kwdict; op->defaults_kwdict = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_kwdefaults(__pyx_CyFunctionObject *op) { PyObject* result = op->defaults_kwdict; if (unlikely(!result)) { if (op->defaults_getter) { if (__Pyx_CyFunction_init_defaults(op) < 0) return NULL; result = op->defaults_kwdict; } else { result = Py_None; } } Py_INCREF(result); return result; } static int __Pyx_CyFunction_set_annotations(__pyx_CyFunctionObject *op, PyObject* value) { PyObject* tmp; if (!value || value == Py_None) { value = NULL; } else if (!PyDict_Check(value)) { PyErr_SetString(PyExc_TypeError, "__annotations__ must be set to a dict object"); return -1; } Py_XINCREF(value); tmp = op->func_annotations; op->func_annotations = value; Py_XDECREF(tmp); return 0; } static PyObject * __Pyx_CyFunction_get_annotations(__pyx_CyFunctionObject *op) { PyObject* result = op->func_annotations; if (unlikely(!result)) { result = PyDict_New(); if (unlikely(!result)) return NULL; op->func_annotations = result; } Py_INCREF(result); return result; } static PyGetSetDef __pyx_CyFunction_getsets[] = { {(char *) "func_doc", (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0}, {(char *) "__doc__", (getter)__Pyx_CyFunction_get_doc, (setter)__Pyx_CyFunction_set_doc, 0, 0}, {(char *) "func_name", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0}, {(char *) "__name__", (getter)__Pyx_CyFunction_get_name, (setter)__Pyx_CyFunction_set_name, 0, 0}, {(char *) "__qualname__", (getter)__Pyx_CyFunction_get_qualname, (setter)__Pyx_CyFunction_set_qualname, 0, 0}, {(char *) "__self__", (getter)__Pyx_CyFunction_get_self, 0, 0, 0}, {(char *) "func_dict", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0}, {(char *) "__dict__", (getter)__Pyx_CyFunction_get_dict, (setter)__Pyx_CyFunction_set_dict, 0, 0}, {(char *) "func_globals", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0}, {(char *) "__globals__", (getter)__Pyx_CyFunction_get_globals, 0, 0, 0}, {(char *) "func_closure", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0}, {(char *) "__closure__", (getter)__Pyx_CyFunction_get_closure, 0, 0, 0}, {(char *) "func_code", (getter)__Pyx_CyFunction_get_code, 0, 0, 0}, {(char *) "__code__", (getter)__Pyx_CyFunction_get_code, 0, 0, 0}, {(char *) "func_defaults", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0}, {(char *) "__defaults__", (getter)__Pyx_CyFunction_get_defaults, (setter)__Pyx_CyFunction_set_defaults, 0, 0}, {(char *) "__kwdefaults__", (getter)__Pyx_CyFunction_get_kwdefaults, (setter)__Pyx_CyFunction_set_kwdefaults, 0, 0}, {(char *) "__annotations__", (getter)__Pyx_CyFunction_get_annotations, (setter)__Pyx_CyFunction_set_annotations, 0, 0}, {0, 0, 0, 0, 0} }; static PyMemberDef __pyx_CyFunction_members[] = { {(char *) "__module__", T_OBJECT, offsetof(__pyx_CyFunctionObject, func.m_module), PY_WRITE_RESTRICTED, 0}, {0, 0, 0, 0, 0} }; static PyObject * __Pyx_CyFunction_reduce(__pyx_CyFunctionObject *m, CYTHON_UNUSED PyObject *args) { #if PY_MAJOR_VERSION >= 3 return PyUnicode_FromString(m->func.m_ml->ml_name); #else return PyString_FromString(m->func.m_ml->ml_name); #endif } static PyMethodDef __pyx_CyFunction_methods[] = { {"__reduce__", (PyCFunction)__Pyx_CyFunction_reduce, METH_VARARGS, 0}, {0, 0, 0, 0} }; #if PY_VERSION_HEX < 0x030500A0 #define __Pyx_CyFunction_weakreflist(cyfunc) ((cyfunc)->func_weakreflist) #else #define __Pyx_CyFunction_weakreflist(cyfunc) ((cyfunc)->func.m_weakreflist) #endif static PyObject *__Pyx_CyFunction_New(PyTypeObject *type, PyMethodDef *ml, int flags, PyObject* qualname, PyObject *closure, PyObject *module, PyObject* globals, PyObject* code) { __pyx_CyFunctionObject *op = PyObject_GC_New(__pyx_CyFunctionObject, type); if (op == NULL) return NULL; op->flags = flags; __Pyx_CyFunction_weakreflist(op) = NULL; op->func.m_ml = ml; op->func.m_self = (PyObject *) op; Py_XINCREF(closure); op->func_closure = closure; Py_XINCREF(module); op->func.m_module = module; op->func_dict = NULL; op->func_name = NULL; Py_INCREF(qualname); op->func_qualname = qualname; op->func_doc = NULL; op->func_classobj = NULL; op->func_globals = globals; Py_INCREF(op->func_globals); Py_XINCREF(code); op->func_code = code; op->defaults_pyobjects = 0; op->defaults = NULL; op->defaults_tuple = NULL; op->defaults_kwdict = NULL; op->defaults_getter = NULL; op->func_annotations = NULL; PyObject_GC_Track(op); return (PyObject *) op; } static int __Pyx_CyFunction_clear(__pyx_CyFunctionObject *m) { Py_CLEAR(m->func_closure); Py_CLEAR(m->func.m_module); Py_CLEAR(m->func_dict); Py_CLEAR(m->func_name); Py_CLEAR(m->func_qualname); Py_CLEAR(m->func_doc); Py_CLEAR(m->func_globals); Py_CLEAR(m->func_code); Py_CLEAR(m->func_classobj); Py_CLEAR(m->defaults_tuple); Py_CLEAR(m->defaults_kwdict); Py_CLEAR(m->func_annotations); if (m->defaults) { PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m); int i; for (i = 0; i < m->defaults_pyobjects; i++) Py_XDECREF(pydefaults[i]); PyObject_Free(m->defaults); m->defaults = NULL; } return 0; } static void __Pyx_CyFunction_dealloc(__pyx_CyFunctionObject *m) { PyObject_GC_UnTrack(m); if (__Pyx_CyFunction_weakreflist(m) != NULL) PyObject_ClearWeakRefs((PyObject *) m); __Pyx_CyFunction_clear(m); PyObject_GC_Del(m); } static int __Pyx_CyFunction_traverse(__pyx_CyFunctionObject *m, visitproc visit, void *arg) { Py_VISIT(m->func_closure); Py_VISIT(m->func.m_module); Py_VISIT(m->func_dict); Py_VISIT(m->func_name); Py_VISIT(m->func_qualname); Py_VISIT(m->func_doc); Py_VISIT(m->func_globals); Py_VISIT(m->func_code); Py_VISIT(m->func_classobj); Py_VISIT(m->defaults_tuple); Py_VISIT(m->defaults_kwdict); if (m->defaults) { PyObject **pydefaults = __Pyx_CyFunction_Defaults(PyObject *, m); int i; for (i = 0; i < m->defaults_pyobjects; i++) Py_VISIT(pydefaults[i]); } return 0; } static PyObject *__Pyx_CyFunction_descr_get(PyObject *func, PyObject *obj, PyObject *type) { __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func; if (m->flags & __Pyx_CYFUNCTION_STATICMETHOD) { Py_INCREF(func); return func; } if (m->flags & __Pyx_CYFUNCTION_CLASSMETHOD) { if (type == NULL) type = (PyObject *)(Py_TYPE(obj)); return __Pyx_PyMethod_New(func, type, (PyObject *)(Py_TYPE(type))); } if (obj == Py_None) obj = NULL; return __Pyx_PyMethod_New(func, obj, type); } static PyObject* __Pyx_CyFunction_repr(__pyx_CyFunctionObject *op) { #if PY_MAJOR_VERSION >= 3 return PyUnicode_FromFormat("", op->func_qualname, (void *)op); #else return PyString_FromFormat("", PyString_AsString(op->func_qualname), (void *)op); #endif } static PyObject * __Pyx_CyFunction_CallMethod(PyObject *func, PyObject *self, PyObject *arg, PyObject *kw) { PyCFunctionObject* f = (PyCFunctionObject*)func; PyCFunction meth = f->m_ml->ml_meth; Py_ssize_t size; switch (f->m_ml->ml_flags & (METH_VARARGS | METH_KEYWORDS | METH_NOARGS | METH_O)) { case METH_VARARGS: if (likely(kw == NULL || PyDict_Size(kw) == 0)) return (*meth)(self, arg); break; case METH_VARARGS | METH_KEYWORDS: return (*(PyCFunctionWithKeywords)meth)(self, arg, kw); case METH_NOARGS: if (likely(kw == NULL || PyDict_Size(kw) == 0)) { size = PyTuple_GET_SIZE(arg); if (likely(size == 0)) return (*meth)(self, NULL); PyErr_Format(PyExc_TypeError, "%.200s() takes no arguments (%" CYTHON_FORMAT_SSIZE_T "d given)", f->m_ml->ml_name, size); return NULL; } break; case METH_O: if (likely(kw == NULL || PyDict_Size(kw) == 0)) { size = PyTuple_GET_SIZE(arg); if (likely(size == 1)) { PyObject *result, *arg0 = PySequence_ITEM(arg, 0); if (unlikely(!arg0)) return NULL; result = (*meth)(self, arg0); Py_DECREF(arg0); return result; } PyErr_Format(PyExc_TypeError, "%.200s() takes exactly one argument (%" CYTHON_FORMAT_SSIZE_T "d given)", f->m_ml->ml_name, size); return NULL; } break; default: PyErr_SetString(PyExc_SystemError, "Bad call flags in " "__Pyx_CyFunction_Call. METH_OLDARGS is no " "longer supported!"); return NULL; } PyErr_Format(PyExc_TypeError, "%.200s() takes no keyword arguments", f->m_ml->ml_name); return NULL; } static CYTHON_INLINE PyObject *__Pyx_CyFunction_Call(PyObject *func, PyObject *arg, PyObject *kw) { return __Pyx_CyFunction_CallMethod(func, ((PyCFunctionObject*)func)->m_self, arg, kw); } static PyObject *__Pyx_CyFunction_CallAsMethod(PyObject *func, PyObject *args, PyObject *kw) { PyObject *result; __pyx_CyFunctionObject *cyfunc = (__pyx_CyFunctionObject *) func; if ((cyfunc->flags & __Pyx_CYFUNCTION_CCLASS) && !(cyfunc->flags & __Pyx_CYFUNCTION_STATICMETHOD)) { Py_ssize_t argc; PyObject *new_args; PyObject *self; argc = PyTuple_GET_SIZE(args); new_args = PyTuple_GetSlice(args, 1, argc); if (unlikely(!new_args)) return NULL; self = PyTuple_GetItem(args, 0); if (unlikely(!self)) { Py_DECREF(new_args); return NULL; } result = __Pyx_CyFunction_CallMethod(func, self, new_args, kw); Py_DECREF(new_args); } else { result = __Pyx_CyFunction_Call(func, args, kw); } return result; } static PyTypeObject __pyx_CyFunctionType_type = { PyVarObject_HEAD_INIT(0, 0) "cython_function_or_method", sizeof(__pyx_CyFunctionObject), 0, (destructor) __Pyx_CyFunction_dealloc, 0, 0, 0, #if PY_MAJOR_VERSION < 3 0, #else 0, #endif (reprfunc) __Pyx_CyFunction_repr, 0, 0, 0, 0, __Pyx_CyFunction_CallAsMethod, 0, 0, 0, 0, Py_TPFLAGS_DEFAULT | Py_TPFLAGS_HAVE_GC, 0, (traverseproc) __Pyx_CyFunction_traverse, (inquiry) __Pyx_CyFunction_clear, 0, #if PY_VERSION_HEX < 0x030500A0 offsetof(__pyx_CyFunctionObject, func_weakreflist), #else offsetof(PyCFunctionObject, m_weakreflist), #endif 0, 0, __pyx_CyFunction_methods, __pyx_CyFunction_members, __pyx_CyFunction_getsets, 0, 0, __Pyx_CyFunction_descr_get, 0, offsetof(__pyx_CyFunctionObject, func_dict), 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, #if PY_VERSION_HEX >= 0x030400a1 0, #endif }; static int __pyx_CyFunction_init(void) { __pyx_CyFunctionType = __Pyx_FetchCommonType(&__pyx_CyFunctionType_type); if (__pyx_CyFunctionType == NULL) { return -1; } return 0; } static CYTHON_INLINE void *__Pyx_CyFunction_InitDefaults(PyObject *func, size_t size, int pyobjects) { __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func; m->defaults = PyObject_Malloc(size); if (!m->defaults) return PyErr_NoMemory(); memset(m->defaults, 0, size); m->defaults_pyobjects = pyobjects; return m->defaults; } static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsTuple(PyObject *func, PyObject *tuple) { __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func; m->defaults_tuple = tuple; Py_INCREF(tuple); } static CYTHON_INLINE void __Pyx_CyFunction_SetDefaultsKwDict(PyObject *func, PyObject *dict) { __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func; m->defaults_kwdict = dict; Py_INCREF(dict); } static CYTHON_INLINE void __Pyx_CyFunction_SetAnnotationsDict(PyObject *func, PyObject *dict) { __pyx_CyFunctionObject *m = (__pyx_CyFunctionObject *) func; m->func_annotations = dict; Py_INCREF(dict); } /* SliceObject */ static CYTHON_INLINE PyObject* __Pyx_PyObject_GetSlice(PyObject* obj, Py_ssize_t cstart, Py_ssize_t cstop, PyObject** _py_start, PyObject** _py_stop, PyObject** _py_slice, int has_cstart, int has_cstop, CYTHON_UNUSED int wraparound) { #if CYTHON_USE_TYPE_SLOTS PyMappingMethods* mp; #if PY_MAJOR_VERSION < 3 PySequenceMethods* ms = Py_TYPE(obj)->tp_as_sequence; if (likely(ms && ms->sq_slice)) { if (!has_cstart) { if (_py_start && (*_py_start != Py_None)) { cstart = __Pyx_PyIndex_AsSsize_t(*_py_start); if ((cstart == (Py_ssize_t)-1) && PyErr_Occurred()) goto bad; } else cstart = 0; } if (!has_cstop) { if (_py_stop && (*_py_stop != Py_None)) { cstop = __Pyx_PyIndex_AsSsize_t(*_py_stop); if ((cstop == (Py_ssize_t)-1) && PyErr_Occurred()) goto bad; } else cstop = PY_SSIZE_T_MAX; } if (wraparound && unlikely((cstart < 0) | (cstop < 0)) && likely(ms->sq_length)) { Py_ssize_t l = ms->sq_length(obj); if (likely(l >= 0)) { if (cstop < 0) { cstop += l; if (cstop < 0) cstop = 0; } if (cstart < 0) { cstart += l; if (cstart < 0) cstart = 0; } } else { if (!PyErr_ExceptionMatches(PyExc_OverflowError)) goto bad; PyErr_Clear(); } } return ms->sq_slice(obj, cstart, cstop); } #endif mp = Py_TYPE(obj)->tp_as_mapping; if (likely(mp && mp->mp_subscript)) #endif { PyObject* result; PyObject *py_slice, *py_start, *py_stop; if (_py_slice) { py_slice = *_py_slice; } else { PyObject* owned_start = NULL; PyObject* owned_stop = NULL; if (_py_start) { py_start = *_py_start; } else { if (has_cstart) { owned_start = py_start = PyInt_FromSsize_t(cstart); if (unlikely(!py_start)) goto bad; } else py_start = Py_None; } if (_py_stop) { py_stop = *_py_stop; } else { if (has_cstop) { owned_stop = py_stop = PyInt_FromSsize_t(cstop); if (unlikely(!py_stop)) { Py_XDECREF(owned_start); goto bad; } } else py_stop = Py_None; } py_slice = PySlice_New(py_start, py_stop, Py_None); Py_XDECREF(owned_start); Py_XDECREF(owned_stop); if (unlikely(!py_slice)) goto bad; } #if CYTHON_USE_TYPE_SLOTS result = mp->mp_subscript(obj, py_slice); #else result = PyObject_GetItem(obj, py_slice); #endif if (!_py_slice) { Py_DECREF(py_slice); } return result; } PyErr_Format(PyExc_TypeError, "'%.200s' object is unsliceable", Py_TYPE(obj)->tp_name); bad: return NULL; } /* ImportFrom */ static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) { PyObject* value = __Pyx_PyObject_GetAttrStr(module, name); if (unlikely(!value) && PyErr_ExceptionMatches(PyExc_AttributeError)) { PyErr_Format(PyExc_ImportError, #if PY_MAJOR_VERSION < 3 "cannot import name %.230s", PyString_AS_STRING(name)); #else "cannot import name %S", name); #endif } return value; } /* decode_c_string */ static CYTHON_INLINE PyObject* __Pyx_decode_c_string( const char* cstring, Py_ssize_t start, Py_ssize_t stop, const char* encoding, const char* errors, PyObject* (*decode_func)(const char *s, Py_ssize_t size, const char *errors)) { Py_ssize_t length; if (unlikely((start < 0) | (stop < 0))) { size_t slen = strlen(cstring); if (unlikely(slen > (size_t) PY_SSIZE_T_MAX)) { PyErr_SetString(PyExc_OverflowError, "c-string too long to convert to Python"); return NULL; } length = (Py_ssize_t) slen; if (start < 0) { start += length; if (start < 0) start = 0; } if (stop < 0) stop += length; } length = stop - start; if (unlikely(length <= 0)) return PyUnicode_FromUnicode(NULL, 0); cstring += start; if (decode_func) { return decode_func(cstring, length, errors); } else { return PyUnicode_Decode(cstring, length, encoding, errors); } } /* Globals */ static PyObject* __Pyx_Globals(void) { Py_ssize_t i; PyObject *names; PyObject *globals = __pyx_d; Py_INCREF(globals); names = PyObject_Dir(__pyx_m); if (!names) goto bad; for (i = PyList_GET_SIZE(names)-1; i >= 0; i--) { #if CYTHON_COMPILING_IN_PYPY PyObject* name = PySequence_ITEM(names, i); if (!name) goto bad; #else PyObject* name = PyList_GET_ITEM(names, i); #endif if (!PyDict_Contains(globals, name)) { PyObject* value = __Pyx_GetAttr(__pyx_m, name); if (!value) { #if CYTHON_COMPILING_IN_PYPY Py_DECREF(name); #endif goto bad; } if (PyDict_SetItem(globals, name, value) < 0) { #if CYTHON_COMPILING_IN_PYPY Py_DECREF(name); #endif Py_DECREF(value); goto bad; } } #if CYTHON_COMPILING_IN_PYPY Py_DECREF(name); #endif } Py_DECREF(names); return globals; bad: Py_XDECREF(names); Py_XDECREF(globals); return NULL; } /* CalculateMetaclass */ static PyObject *__Pyx_CalculateMetaclass(PyTypeObject *metaclass, PyObject *bases) { Py_ssize_t i, nbases = PyTuple_GET_SIZE(bases); for (i=0; i < nbases; i++) { PyTypeObject *tmptype; PyObject *tmp = PyTuple_GET_ITEM(bases, i); tmptype = Py_TYPE(tmp); #if PY_MAJOR_VERSION < 3 if (tmptype == &PyClass_Type) continue; #endif if (!metaclass) { metaclass = tmptype; continue; } if (PyType_IsSubtype(metaclass, tmptype)) continue; if (PyType_IsSubtype(tmptype, metaclass)) { metaclass = tmptype; continue; } PyErr_SetString(PyExc_TypeError, "metaclass conflict: " "the metaclass of a derived class " "must be a (non-strict) subclass " "of the metaclasses of all its bases"); return NULL; } if (!metaclass) { #if PY_MAJOR_VERSION < 3 metaclass = &PyClass_Type; #else metaclass = &PyType_Type; #endif } Py_INCREF((PyObject*) metaclass); return (PyObject*) metaclass; } /* Py3ClassCreate */ static PyObject *__Pyx_Py3MetaclassPrepare(PyObject *metaclass, PyObject *bases, PyObject *name, PyObject *qualname, PyObject *mkw, PyObject *modname, PyObject *doc) { PyObject *ns; if (metaclass) { PyObject *prep = __Pyx_PyObject_GetAttrStr(metaclass, __pyx_n_s_prepare); if (prep) { PyObject *pargs = PyTuple_Pack(2, name, bases); if (unlikely(!pargs)) { Py_DECREF(prep); return NULL; } ns = PyObject_Call(prep, pargs, mkw); Py_DECREF(prep); Py_DECREF(pargs); } else { if (unlikely(!PyErr_ExceptionMatches(PyExc_AttributeError))) return NULL; PyErr_Clear(); ns = PyDict_New(); } } else { ns = PyDict_New(); } if (unlikely(!ns)) return NULL; if (unlikely(PyObject_SetItem(ns, __pyx_n_s_module, modname) < 0)) goto bad; if (unlikely(PyObject_SetItem(ns, __pyx_n_s_qualname, qualname) < 0)) goto bad; if (unlikely(doc && PyObject_SetItem(ns, __pyx_n_s_doc, doc) < 0)) goto bad; return ns; bad: Py_DECREF(ns); return NULL; } static PyObject *__Pyx_Py3ClassCreate(PyObject *metaclass, PyObject *name, PyObject *bases, PyObject *dict, PyObject *mkw, int calculate_metaclass, int allow_py2_metaclass) { PyObject *result, *margs; PyObject *owned_metaclass = NULL; if (allow_py2_metaclass) { owned_metaclass = PyObject_GetItem(dict, __pyx_n_s_metaclass); if (owned_metaclass) { metaclass = owned_metaclass; } else if (likely(PyErr_ExceptionMatches(PyExc_KeyError))) { PyErr_Clear(); } else { return NULL; } } if (calculate_metaclass && (!metaclass || PyType_Check(metaclass))) { metaclass = __Pyx_CalculateMetaclass((PyTypeObject*) metaclass, bases); Py_XDECREF(owned_metaclass); if (unlikely(!metaclass)) return NULL; owned_metaclass = metaclass; } margs = PyTuple_Pack(3, name, bases, dict); if (unlikely(!margs)) { result = NULL; } else { result = PyObject_Call(metaclass, margs, mkw); Py_DECREF(margs); } Py_XDECREF(owned_metaclass); return result; } /* CodeObjectCache */ static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) { int start = 0, mid = 0, end = count - 1; if (end >= 0 && code_line > entries[end].code_line) { return count; } while (start < end) { mid = start + (end - start) / 2; if (code_line < entries[mid].code_line) { end = mid; } else if (code_line > entries[mid].code_line) { start = mid + 1; } else { return mid; } } if (code_line <= entries[mid].code_line) { return mid; } else { return mid + 1; } } static PyCodeObject *__pyx_find_code_object(int code_line) { PyCodeObject* code_object; int pos; if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) { return NULL; } pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line); if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) { return NULL; } code_object = __pyx_code_cache.entries[pos].code_object; Py_INCREF(code_object); return code_object; } static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) { int pos, i; __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries; if (unlikely(!code_line)) { return; } if (unlikely(!entries)) { entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry)); if (likely(entries)) { __pyx_code_cache.entries = entries; __pyx_code_cache.max_count = 64; __pyx_code_cache.count = 1; entries[0].code_line = code_line; entries[0].code_object = code_object; Py_INCREF(code_object); } return; } pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line); if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) { PyCodeObject* tmp = entries[pos].code_object; entries[pos].code_object = code_object; Py_DECREF(tmp); return; } if (__pyx_code_cache.count == __pyx_code_cache.max_count) { int new_max = __pyx_code_cache.max_count + 64; entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc( __pyx_code_cache.entries, (size_t)new_max*sizeof(__Pyx_CodeObjectCacheEntry)); if (unlikely(!entries)) { return; } __pyx_code_cache.entries = entries; __pyx_code_cache.max_count = new_max; } for (i=__pyx_code_cache.count; i>pos; i--) { entries[i] = entries[i-1]; } entries[pos].code_line = code_line; entries[pos].code_object = code_object; __pyx_code_cache.count++; Py_INCREF(code_object); } /* AddTraceback */ #include "compile.h" #include "frameobject.h" #include "traceback.h" static PyCodeObject* __Pyx_CreateCodeObjectForTraceback( const char *funcname, int c_line, int py_line, const char *filename) { PyCodeObject *py_code = 0; PyObject *py_srcfile = 0; PyObject *py_funcname = 0; #if PY_MAJOR_VERSION < 3 py_srcfile = PyString_FromString(filename); #else py_srcfile = PyUnicode_FromString(filename); #endif if (!py_srcfile) goto bad; if (c_line) { #if PY_MAJOR_VERSION < 3 py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line); #else py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line); #endif } else { #if PY_MAJOR_VERSION < 3 py_funcname = PyString_FromString(funcname); #else py_funcname = PyUnicode_FromString(funcname); #endif } if (!py_funcname) goto bad; py_code = __Pyx_PyCode_New( 0, 0, 0, 0, 0, __pyx_empty_bytes, /*PyObject *code,*/ __pyx_empty_tuple, /*PyObject *consts,*/ __pyx_empty_tuple, /*PyObject *names,*/ __pyx_empty_tuple, /*PyObject *varnames,*/ __pyx_empty_tuple, /*PyObject *freevars,*/ __pyx_empty_tuple, /*PyObject *cellvars,*/ py_srcfile, /*PyObject *filename,*/ py_funcname, /*PyObject *name,*/ py_line, __pyx_empty_bytes /*PyObject *lnotab*/ ); Py_DECREF(py_srcfile); Py_DECREF(py_funcname); return py_code; bad: Py_XDECREF(py_srcfile); Py_XDECREF(py_funcname); return NULL; } static void __Pyx_AddTraceback(const char *funcname, int c_line, int py_line, const char *filename) { PyCodeObject *py_code = 0; PyFrameObject *py_frame = 0; py_code = __pyx_find_code_object(c_line ? c_line : py_line); if (!py_code) { py_code = __Pyx_CreateCodeObjectForTraceback( funcname, c_line, py_line, filename); if (!py_code) goto bad; __pyx_insert_code_object(c_line ? c_line : py_line, py_code); } py_frame = PyFrame_New( PyThreadState_GET(), /*PyThreadState *tstate,*/ py_code, /*PyCodeObject *code,*/ __pyx_d, /*PyObject *globals,*/ 0 /*PyObject *locals*/ ); if (!py_frame) goto bad; __Pyx_PyFrame_SetLineNumber(py_frame, py_line); PyTraceBack_Here(py_frame); bad: Py_XDECREF(py_code); Py_XDECREF(py_frame); } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) { const int neg_one = (int) -1, const_zero = (int) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(int) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(int) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(int) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(int), little, !is_unsigned); } } /* CIntFromPyVerify */ #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\ __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0) #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\ __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1) #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\ {\ func_type value = func_value;\ if (sizeof(target_type) < sizeof(func_type)) {\ if (unlikely(value != (func_type) (target_type) value)) {\ func_type zero = 0;\ if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\ return (target_type) -1;\ if (is_unsigned && unlikely(value < zero))\ goto raise_neg_overflow;\ else\ goto raise_overflow;\ }\ }\ return (target_type) value;\ } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) { const long neg_one = (long) -1, const_zero = (long) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(long) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(long) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(long) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(long), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fuse_ino_t(fuse_ino_t value) { const fuse_ino_t neg_one = (fuse_ino_t) -1, const_zero = (fuse_ino_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(fuse_ino_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(fuse_ino_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fuse_ino_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(fuse_ino_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fuse_ino_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(fuse_ino_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_unsigned_long(unsigned long value) { const unsigned long neg_one = (unsigned long) -1, const_zero = (unsigned long) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(unsigned long) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(unsigned long) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(unsigned long) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(unsigned long) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(unsigned long) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(unsigned long), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uint64_t(uint64_t value) { const uint64_t neg_one = (uint64_t) -1, const_zero = (uint64_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(uint64_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(uint64_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uint64_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(uint64_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uint64_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(uint64_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_mode_t(mode_t value) { const mode_t neg_one = (mode_t) -1, const_zero = (mode_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(mode_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(mode_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(mode_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(mode_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(mode_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(mode_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_dev_t(dev_t value) { const dev_t neg_one = (dev_t) -1, const_zero = (dev_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(dev_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(dev_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(dev_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(dev_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(dev_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(dev_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_off_t(off_t value) { const off_t neg_one = (off_t) -1, const_zero = (off_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(off_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(off_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(off_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(off_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(off_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(off_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uint32_t(uint32_t value) { const uint32_t neg_one = (uint32_t) -1, const_zero = (uint32_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(uint32_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(uint32_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uint32_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(uint32_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uint32_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(uint32_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_uid_t(uid_t value) { const uid_t neg_one = (uid_t) -1, const_zero = (uid_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(uid_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(uid_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uid_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(uid_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(uid_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(uid_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_pid_t(pid_t value) { const pid_t neg_one = (pid_t) -1, const_zero = (pid_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(pid_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(pid_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(pid_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(pid_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(pid_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(pid_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_gid_t(gid_t value) { const gid_t neg_one = (gid_t) -1, const_zero = (gid_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(gid_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(gid_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(gid_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(gid_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(gid_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(gid_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_nlink_t(nlink_t value) { const nlink_t neg_one = (nlink_t) -1, const_zero = (nlink_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(nlink_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(nlink_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(nlink_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(nlink_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(nlink_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(nlink_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_blkcnt_t(blkcnt_t value) { const blkcnt_t neg_one = (blkcnt_t) -1, const_zero = (blkcnt_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(blkcnt_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(blkcnt_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(blkcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(blkcnt_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(blkcnt_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(blkcnt_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_blksize_t(blksize_t value) { const blksize_t neg_one = (blksize_t) -1, const_zero = (blksize_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(blksize_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(blksize_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(blksize_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(blksize_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(blksize_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(blksize_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_time_t(time_t value) { const time_t neg_one = (time_t) -1, const_zero = (time_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(time_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(time_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(time_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(time_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(time_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(time_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fsblkcnt_t(fsblkcnt_t value) { const fsblkcnt_t neg_one = (fsblkcnt_t) -1, const_zero = (fsblkcnt_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(fsblkcnt_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(fsblkcnt_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fsblkcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(fsblkcnt_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fsblkcnt_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(fsblkcnt_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_fsfilcnt_t(fsfilcnt_t value) { const fsfilcnt_t neg_one = (fsfilcnt_t) -1, const_zero = (fsfilcnt_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(fsfilcnt_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(fsfilcnt_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fsfilcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(fsfilcnt_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(fsfilcnt_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(fsfilcnt_t), little, !is_unsigned); } } /* CIntToPy */ static CYTHON_INLINE PyObject* __Pyx_PyInt_From_pthread_t(pthread_t value) { const pthread_t neg_one = (pthread_t) -1, const_zero = (pthread_t) 0; const int is_unsigned = neg_one > const_zero; if (is_unsigned) { if (sizeof(pthread_t) < sizeof(long)) { return PyInt_FromLong((long) value); } else if (sizeof(pthread_t) <= sizeof(unsigned long)) { return PyLong_FromUnsignedLong((unsigned long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(pthread_t) <= sizeof(unsigned PY_LONG_LONG)) { return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value); #endif } } else { if (sizeof(pthread_t) <= sizeof(long)) { return PyInt_FromLong((long) value); #ifdef HAVE_LONG_LONG } else if (sizeof(pthread_t) <= sizeof(PY_LONG_LONG)) { return PyLong_FromLongLong((PY_LONG_LONG) value); #endif } } { int one = 1; int little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&value; return _PyLong_FromByteArray(bytes, sizeof(pthread_t), little, !is_unsigned); } } /* CIntFromPy */ static CYTHON_INLINE size_t __Pyx_PyInt_As_size_t(PyObject *x) { const size_t neg_one = (size_t) -1, const_zero = (size_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(size_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(size_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (size_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (size_t) 0; case 1: __PYX_VERIFY_RETURN_INT(size_t, digit, digits[0]) case 2: if (8 * sizeof(size_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) >= 2 * PyLong_SHIFT) { return (size_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } } break; case 3: if (8 * sizeof(size_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) >= 3 * PyLong_SHIFT) { return (size_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } } break; case 4: if (8 * sizeof(size_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) >= 4 * PyLong_SHIFT) { return (size_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (size_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(size_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(size_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(size_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(size_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (size_t) 0; case -1: __PYX_VERIFY_RETURN_INT(size_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(size_t, digit, +digits[0]) case -2: if (8 * sizeof(size_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) { return (size_t) (((size_t)-1)*(((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; case 2: if (8 * sizeof(size_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) { return (size_t) ((((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; case -3: if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) { return (size_t) (((size_t)-1)*(((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; case 3: if (8 * sizeof(size_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) { return (size_t) ((((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; case -4: if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 4 * PyLong_SHIFT) { return (size_t) (((size_t)-1)*(((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; case 4: if (8 * sizeof(size_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(size_t) - 1 > 4 * PyLong_SHIFT) { return (size_t) ((((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]))); } } break; } #endif if (sizeof(size_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(size_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(size_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(size_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else size_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (size_t) -1; } } else { size_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (size_t) -1; val = __Pyx_PyInt_As_size_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to size_t"); return (size_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to size_t"); return (size_t) -1; } /* CIntFromPy */ static CYTHON_INLINE fuse_ino_t __Pyx_PyInt_As_fuse_ino_t(PyObject *x) { const fuse_ino_t neg_one = (fuse_ino_t) -1, const_zero = (fuse_ino_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(fuse_ino_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (fuse_ino_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fuse_ino_t) 0; case 1: __PYX_VERIFY_RETURN_INT(fuse_ino_t, digit, digits[0]) case 2: if (8 * sizeof(fuse_ino_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) >= 2 * PyLong_SHIFT) { return (fuse_ino_t) (((((fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0])); } } break; case 3: if (8 * sizeof(fuse_ino_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) >= 3 * PyLong_SHIFT) { return (fuse_ino_t) (((((((fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0])); } } break; case 4: if (8 * sizeof(fuse_ino_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) >= 4 * PyLong_SHIFT) { return (fuse_ino_t) (((((((((fuse_ino_t)digits[3]) << PyLong_SHIFT) | (fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (fuse_ino_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(fuse_ino_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(fuse_ino_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fuse_ino_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fuse_ino_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fuse_ino_t) 0; case -1: __PYX_VERIFY_RETURN_INT(fuse_ino_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(fuse_ino_t, digit, +digits[0]) case -2: if (8 * sizeof(fuse_ino_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 2 * PyLong_SHIFT) { return (fuse_ino_t) (((fuse_ino_t)-1)*(((((fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; case 2: if (8 * sizeof(fuse_ino_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 2 * PyLong_SHIFT) { return (fuse_ino_t) ((((((fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; case -3: if (8 * sizeof(fuse_ino_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 3 * PyLong_SHIFT) { return (fuse_ino_t) (((fuse_ino_t)-1)*(((((((fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; case 3: if (8 * sizeof(fuse_ino_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 3 * PyLong_SHIFT) { return (fuse_ino_t) ((((((((fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; case -4: if (8 * sizeof(fuse_ino_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 4 * PyLong_SHIFT) { return (fuse_ino_t) (((fuse_ino_t)-1)*(((((((((fuse_ino_t)digits[3]) << PyLong_SHIFT) | (fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; case 4: if (8 * sizeof(fuse_ino_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fuse_ino_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fuse_ino_t) - 1 > 4 * PyLong_SHIFT) { return (fuse_ino_t) ((((((((((fuse_ino_t)digits[3]) << PyLong_SHIFT) | (fuse_ino_t)digits[2]) << PyLong_SHIFT) | (fuse_ino_t)digits[1]) << PyLong_SHIFT) | (fuse_ino_t)digits[0]))); } } break; } #endif if (sizeof(fuse_ino_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(fuse_ino_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fuse_ino_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fuse_ino_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else fuse_ino_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (fuse_ino_t) -1; } } else { fuse_ino_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (fuse_ino_t) -1; val = __Pyx_PyInt_As_fuse_ino_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to fuse_ino_t"); return (fuse_ino_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to fuse_ino_t"); return (fuse_ino_t) -1; } /* CIntFromPy */ static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) { const int neg_one = (int) -1, const_zero = (int) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(int) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (int) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (int) 0; case 1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0]) case 2: if (8 * sizeof(int) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) { return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])); } } break; case 3: if (8 * sizeof(int) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) { return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])); } } break; case 4: if (8 * sizeof(int) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) { return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (int) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(int) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (int) 0; case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(int, digit, +digits[0]) case -2: if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) { return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; case 2: if (8 * sizeof(int) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) { return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; case -3: if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) { return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; case 3: if (8 * sizeof(int) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) { return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; case -4: if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) { return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; case 4: if (8 * sizeof(int) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) { return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]))); } } break; } #endif if (sizeof(int) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else int val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (int) -1; } } else { int val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (int) -1; val = __Pyx_PyInt_As_int(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to int"); return (int) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to int"); return (int) -1; } /* CIntFromPy */ static CYTHON_INLINE uint64_t __Pyx_PyInt_As_uint64_t(PyObject *x) { const uint64_t neg_one = (uint64_t) -1, const_zero = (uint64_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(uint64_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(uint64_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (uint64_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (uint64_t) 0; case 1: __PYX_VERIFY_RETURN_INT(uint64_t, digit, digits[0]) case 2: if (8 * sizeof(uint64_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) >= 2 * PyLong_SHIFT) { return (uint64_t) (((((uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0])); } } break; case 3: if (8 * sizeof(uint64_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) >= 3 * PyLong_SHIFT) { return (uint64_t) (((((((uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0])); } } break; case 4: if (8 * sizeof(uint64_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) >= 4 * PyLong_SHIFT) { return (uint64_t) (((((((((uint64_t)digits[3]) << PyLong_SHIFT) | (uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (uint64_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(uint64_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(uint64_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(uint64_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(uint64_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (uint64_t) 0; case -1: __PYX_VERIFY_RETURN_INT(uint64_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(uint64_t, digit, +digits[0]) case -2: if (8 * sizeof(uint64_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 2 * PyLong_SHIFT) { return (uint64_t) (((uint64_t)-1)*(((((uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; case 2: if (8 * sizeof(uint64_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 2 * PyLong_SHIFT) { return (uint64_t) ((((((uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; case -3: if (8 * sizeof(uint64_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 3 * PyLong_SHIFT) { return (uint64_t) (((uint64_t)-1)*(((((((uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; case 3: if (8 * sizeof(uint64_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 3 * PyLong_SHIFT) { return (uint64_t) ((((((((uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; case -4: if (8 * sizeof(uint64_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 4 * PyLong_SHIFT) { return (uint64_t) (((uint64_t)-1)*(((((((((uint64_t)digits[3]) << PyLong_SHIFT) | (uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; case 4: if (8 * sizeof(uint64_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uint64_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uint64_t) - 1 > 4 * PyLong_SHIFT) { return (uint64_t) ((((((((((uint64_t)digits[3]) << PyLong_SHIFT) | (uint64_t)digits[2]) << PyLong_SHIFT) | (uint64_t)digits[1]) << PyLong_SHIFT) | (uint64_t)digits[0]))); } } break; } #endif if (sizeof(uint64_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(uint64_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(uint64_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(uint64_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else uint64_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (uint64_t) -1; } } else { uint64_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (uint64_t) -1; val = __Pyx_PyInt_As_uint64_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to uint64_t"); return (uint64_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to uint64_t"); return (uint64_t) -1; } /* CIntFromPy */ static CYTHON_INLINE off_t __Pyx_PyInt_As_off_t(PyObject *x) { const off_t neg_one = (off_t) -1, const_zero = (off_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(off_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(off_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (off_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (off_t) 0; case 1: __PYX_VERIFY_RETURN_INT(off_t, digit, digits[0]) case 2: if (8 * sizeof(off_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) >= 2 * PyLong_SHIFT) { return (off_t) (((((off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0])); } } break; case 3: if (8 * sizeof(off_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) >= 3 * PyLong_SHIFT) { return (off_t) (((((((off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0])); } } break; case 4: if (8 * sizeof(off_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) >= 4 * PyLong_SHIFT) { return (off_t) (((((((((off_t)digits[3]) << PyLong_SHIFT) | (off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (off_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(off_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(off_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(off_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(off_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (off_t) 0; case -1: __PYX_VERIFY_RETURN_INT(off_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(off_t, digit, +digits[0]) case -2: if (8 * sizeof(off_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 2 * PyLong_SHIFT) { return (off_t) (((off_t)-1)*(((((off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; case 2: if (8 * sizeof(off_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 2 * PyLong_SHIFT) { return (off_t) ((((((off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; case -3: if (8 * sizeof(off_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 3 * PyLong_SHIFT) { return (off_t) (((off_t)-1)*(((((((off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; case 3: if (8 * sizeof(off_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 3 * PyLong_SHIFT) { return (off_t) ((((((((off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; case -4: if (8 * sizeof(off_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 4 * PyLong_SHIFT) { return (off_t) (((off_t)-1)*(((((((((off_t)digits[3]) << PyLong_SHIFT) | (off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; case 4: if (8 * sizeof(off_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(off_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(off_t) - 1 > 4 * PyLong_SHIFT) { return (off_t) ((((((((((off_t)digits[3]) << PyLong_SHIFT) | (off_t)digits[2]) << PyLong_SHIFT) | (off_t)digits[1]) << PyLong_SHIFT) | (off_t)digits[0]))); } } break; } #endif if (sizeof(off_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(off_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(off_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(off_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else off_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (off_t) -1; } } else { off_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (off_t) -1; val = __Pyx_PyInt_As_off_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to off_t"); return (off_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to off_t"); return (off_t) -1; } /* CIntFromPy */ static CYTHON_INLINE ino_t __Pyx_PyInt_As_ino_t(PyObject *x) { const ino_t neg_one = (ino_t) -1, const_zero = (ino_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(ino_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(ino_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (ino_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (ino_t) 0; case 1: __PYX_VERIFY_RETURN_INT(ino_t, digit, digits[0]) case 2: if (8 * sizeof(ino_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) >= 2 * PyLong_SHIFT) { return (ino_t) (((((ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0])); } } break; case 3: if (8 * sizeof(ino_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) >= 3 * PyLong_SHIFT) { return (ino_t) (((((((ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0])); } } break; case 4: if (8 * sizeof(ino_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) >= 4 * PyLong_SHIFT) { return (ino_t) (((((((((ino_t)digits[3]) << PyLong_SHIFT) | (ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (ino_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(ino_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(ino_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(ino_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(ino_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (ino_t) 0; case -1: __PYX_VERIFY_RETURN_INT(ino_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(ino_t, digit, +digits[0]) case -2: if (8 * sizeof(ino_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 2 * PyLong_SHIFT) { return (ino_t) (((ino_t)-1)*(((((ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; case 2: if (8 * sizeof(ino_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 2 * PyLong_SHIFT) { return (ino_t) ((((((ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; case -3: if (8 * sizeof(ino_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 3 * PyLong_SHIFT) { return (ino_t) (((ino_t)-1)*(((((((ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; case 3: if (8 * sizeof(ino_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 3 * PyLong_SHIFT) { return (ino_t) ((((((((ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; case -4: if (8 * sizeof(ino_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 4 * PyLong_SHIFT) { return (ino_t) (((ino_t)-1)*(((((((((ino_t)digits[3]) << PyLong_SHIFT) | (ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; case 4: if (8 * sizeof(ino_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(ino_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(ino_t) - 1 > 4 * PyLong_SHIFT) { return (ino_t) ((((((((((ino_t)digits[3]) << PyLong_SHIFT) | (ino_t)digits[2]) << PyLong_SHIFT) | (ino_t)digits[1]) << PyLong_SHIFT) | (ino_t)digits[0]))); } } break; } #endif if (sizeof(ino_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(ino_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(ino_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(ino_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else ino_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (ino_t) -1; } } else { ino_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (ino_t) -1; val = __Pyx_PyInt_As_ino_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to ino_t"); return (ino_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to ino_t"); return (ino_t) -1; } /* CIntFromPy */ static CYTHON_INLINE unsigned long __Pyx_PyInt_As_unsigned_long(PyObject *x) { const unsigned long neg_one = (unsigned long) -1, const_zero = (unsigned long) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(unsigned long) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(unsigned long, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (unsigned long) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (unsigned long) 0; case 1: __PYX_VERIFY_RETURN_INT(unsigned long, digit, digits[0]) case 2: if (8 * sizeof(unsigned long) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) >= 2 * PyLong_SHIFT) { return (unsigned long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); } } break; case 3: if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) >= 3 * PyLong_SHIFT) { return (unsigned long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); } } break; case 4: if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) >= 4 * PyLong_SHIFT) { return (unsigned long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (unsigned long) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(unsigned long) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(unsigned long, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(unsigned long) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(unsigned long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (unsigned long) 0; case -1: __PYX_VERIFY_RETURN_INT(unsigned long, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(unsigned long, digit, +digits[0]) case -2: if (8 * sizeof(unsigned long) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 2 * PyLong_SHIFT) { return (unsigned long) (((unsigned long)-1)*(((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; case 2: if (8 * sizeof(unsigned long) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 2 * PyLong_SHIFT) { return (unsigned long) ((((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; case -3: if (8 * sizeof(unsigned long) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 3 * PyLong_SHIFT) { return (unsigned long) (((unsigned long)-1)*(((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; case 3: if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 3 * PyLong_SHIFT) { return (unsigned long) ((((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; case -4: if (8 * sizeof(unsigned long) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 4 * PyLong_SHIFT) { return (unsigned long) (((unsigned long)-1)*(((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; case 4: if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(unsigned long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(unsigned long) - 1 > 4 * PyLong_SHIFT) { return (unsigned long) ((((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))); } } break; } #endif if (sizeof(unsigned long) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(unsigned long, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(unsigned long) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(unsigned long, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else unsigned long val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (unsigned long) -1; } } else { unsigned long val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (unsigned long) -1; val = __Pyx_PyInt_As_unsigned_long(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to unsigned long"); return (unsigned long) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to unsigned long"); return (unsigned long) -1; } /* CIntFromPy */ static CYTHON_INLINE mode_t __Pyx_PyInt_As_mode_t(PyObject *x) { const mode_t neg_one = (mode_t) -1, const_zero = (mode_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(mode_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(mode_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (mode_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (mode_t) 0; case 1: __PYX_VERIFY_RETURN_INT(mode_t, digit, digits[0]) case 2: if (8 * sizeof(mode_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) >= 2 * PyLong_SHIFT) { return (mode_t) (((((mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0])); } } break; case 3: if (8 * sizeof(mode_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) >= 3 * PyLong_SHIFT) { return (mode_t) (((((((mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0])); } } break; case 4: if (8 * sizeof(mode_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) >= 4 * PyLong_SHIFT) { return (mode_t) (((((((((mode_t)digits[3]) << PyLong_SHIFT) | (mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (mode_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(mode_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(mode_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(mode_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(mode_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (mode_t) 0; case -1: __PYX_VERIFY_RETURN_INT(mode_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(mode_t, digit, +digits[0]) case -2: if (8 * sizeof(mode_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 2 * PyLong_SHIFT) { return (mode_t) (((mode_t)-1)*(((((mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; case 2: if (8 * sizeof(mode_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 2 * PyLong_SHIFT) { return (mode_t) ((((((mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; case -3: if (8 * sizeof(mode_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 3 * PyLong_SHIFT) { return (mode_t) (((mode_t)-1)*(((((((mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; case 3: if (8 * sizeof(mode_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 3 * PyLong_SHIFT) { return (mode_t) ((((((((mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; case -4: if (8 * sizeof(mode_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 4 * PyLong_SHIFT) { return (mode_t) (((mode_t)-1)*(((((((((mode_t)digits[3]) << PyLong_SHIFT) | (mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; case 4: if (8 * sizeof(mode_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(mode_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(mode_t) - 1 > 4 * PyLong_SHIFT) { return (mode_t) ((((((((((mode_t)digits[3]) << PyLong_SHIFT) | (mode_t)digits[2]) << PyLong_SHIFT) | (mode_t)digits[1]) << PyLong_SHIFT) | (mode_t)digits[0]))); } } break; } #endif if (sizeof(mode_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(mode_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(mode_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(mode_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else mode_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (mode_t) -1; } } else { mode_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (mode_t) -1; val = __Pyx_PyInt_As_mode_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to mode_t"); return (mode_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to mode_t"); return (mode_t) -1; } /* CIntFromPy */ static CYTHON_INLINE nlink_t __Pyx_PyInt_As_nlink_t(PyObject *x) { const nlink_t neg_one = (nlink_t) -1, const_zero = (nlink_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(nlink_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(nlink_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (nlink_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (nlink_t) 0; case 1: __PYX_VERIFY_RETURN_INT(nlink_t, digit, digits[0]) case 2: if (8 * sizeof(nlink_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) >= 2 * PyLong_SHIFT) { return (nlink_t) (((((nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0])); } } break; case 3: if (8 * sizeof(nlink_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) >= 3 * PyLong_SHIFT) { return (nlink_t) (((((((nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0])); } } break; case 4: if (8 * sizeof(nlink_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) >= 4 * PyLong_SHIFT) { return (nlink_t) (((((((((nlink_t)digits[3]) << PyLong_SHIFT) | (nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (nlink_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(nlink_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(nlink_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(nlink_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(nlink_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (nlink_t) 0; case -1: __PYX_VERIFY_RETURN_INT(nlink_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(nlink_t, digit, +digits[0]) case -2: if (8 * sizeof(nlink_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 2 * PyLong_SHIFT) { return (nlink_t) (((nlink_t)-1)*(((((nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; case 2: if (8 * sizeof(nlink_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 2 * PyLong_SHIFT) { return (nlink_t) ((((((nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; case -3: if (8 * sizeof(nlink_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 3 * PyLong_SHIFT) { return (nlink_t) (((nlink_t)-1)*(((((((nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; case 3: if (8 * sizeof(nlink_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 3 * PyLong_SHIFT) { return (nlink_t) ((((((((nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; case -4: if (8 * sizeof(nlink_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 4 * PyLong_SHIFT) { return (nlink_t) (((nlink_t)-1)*(((((((((nlink_t)digits[3]) << PyLong_SHIFT) | (nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; case 4: if (8 * sizeof(nlink_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(nlink_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(nlink_t) - 1 > 4 * PyLong_SHIFT) { return (nlink_t) ((((((((((nlink_t)digits[3]) << PyLong_SHIFT) | (nlink_t)digits[2]) << PyLong_SHIFT) | (nlink_t)digits[1]) << PyLong_SHIFT) | (nlink_t)digits[0]))); } } break; } #endif if (sizeof(nlink_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(nlink_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(nlink_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(nlink_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else nlink_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (nlink_t) -1; } } else { nlink_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (nlink_t) -1; val = __Pyx_PyInt_As_nlink_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to nlink_t"); return (nlink_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to nlink_t"); return (nlink_t) -1; } /* CIntFromPy */ static CYTHON_INLINE uid_t __Pyx_PyInt_As_uid_t(PyObject *x) { const uid_t neg_one = (uid_t) -1, const_zero = (uid_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(uid_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(uid_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (uid_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (uid_t) 0; case 1: __PYX_VERIFY_RETURN_INT(uid_t, digit, digits[0]) case 2: if (8 * sizeof(uid_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) >= 2 * PyLong_SHIFT) { return (uid_t) (((((uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0])); } } break; case 3: if (8 * sizeof(uid_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) >= 3 * PyLong_SHIFT) { return (uid_t) (((((((uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0])); } } break; case 4: if (8 * sizeof(uid_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) >= 4 * PyLong_SHIFT) { return (uid_t) (((((((((uid_t)digits[3]) << PyLong_SHIFT) | (uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (uid_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(uid_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(uid_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(uid_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(uid_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (uid_t) 0; case -1: __PYX_VERIFY_RETURN_INT(uid_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(uid_t, digit, +digits[0]) case -2: if (8 * sizeof(uid_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 2 * PyLong_SHIFT) { return (uid_t) (((uid_t)-1)*(((((uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; case 2: if (8 * sizeof(uid_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 2 * PyLong_SHIFT) { return (uid_t) ((((((uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; case -3: if (8 * sizeof(uid_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 3 * PyLong_SHIFT) { return (uid_t) (((uid_t)-1)*(((((((uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; case 3: if (8 * sizeof(uid_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 3 * PyLong_SHIFT) { return (uid_t) ((((((((uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; case -4: if (8 * sizeof(uid_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 4 * PyLong_SHIFT) { return (uid_t) (((uid_t)-1)*(((((((((uid_t)digits[3]) << PyLong_SHIFT) | (uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; case 4: if (8 * sizeof(uid_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(uid_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(uid_t) - 1 > 4 * PyLong_SHIFT) { return (uid_t) ((((((((((uid_t)digits[3]) << PyLong_SHIFT) | (uid_t)digits[2]) << PyLong_SHIFT) | (uid_t)digits[1]) << PyLong_SHIFT) | (uid_t)digits[0]))); } } break; } #endif if (sizeof(uid_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(uid_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(uid_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(uid_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else uid_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (uid_t) -1; } } else { uid_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (uid_t) -1; val = __Pyx_PyInt_As_uid_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to uid_t"); return (uid_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to uid_t"); return (uid_t) -1; } /* CIntFromPy */ static CYTHON_INLINE gid_t __Pyx_PyInt_As_gid_t(PyObject *x) { const gid_t neg_one = (gid_t) -1, const_zero = (gid_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(gid_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(gid_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (gid_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (gid_t) 0; case 1: __PYX_VERIFY_RETURN_INT(gid_t, digit, digits[0]) case 2: if (8 * sizeof(gid_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) >= 2 * PyLong_SHIFT) { return (gid_t) (((((gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0])); } } break; case 3: if (8 * sizeof(gid_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) >= 3 * PyLong_SHIFT) { return (gid_t) (((((((gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0])); } } break; case 4: if (8 * sizeof(gid_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) >= 4 * PyLong_SHIFT) { return (gid_t) (((((((((gid_t)digits[3]) << PyLong_SHIFT) | (gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (gid_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(gid_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(gid_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(gid_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(gid_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (gid_t) 0; case -1: __PYX_VERIFY_RETURN_INT(gid_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(gid_t, digit, +digits[0]) case -2: if (8 * sizeof(gid_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 2 * PyLong_SHIFT) { return (gid_t) (((gid_t)-1)*(((((gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; case 2: if (8 * sizeof(gid_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 2 * PyLong_SHIFT) { return (gid_t) ((((((gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; case -3: if (8 * sizeof(gid_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 3 * PyLong_SHIFT) { return (gid_t) (((gid_t)-1)*(((((((gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; case 3: if (8 * sizeof(gid_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 3 * PyLong_SHIFT) { return (gid_t) ((((((((gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; case -4: if (8 * sizeof(gid_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 4 * PyLong_SHIFT) { return (gid_t) (((gid_t)-1)*(((((((((gid_t)digits[3]) << PyLong_SHIFT) | (gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; case 4: if (8 * sizeof(gid_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(gid_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(gid_t) - 1 > 4 * PyLong_SHIFT) { return (gid_t) ((((((((((gid_t)digits[3]) << PyLong_SHIFT) | (gid_t)digits[2]) << PyLong_SHIFT) | (gid_t)digits[1]) << PyLong_SHIFT) | (gid_t)digits[0]))); } } break; } #endif if (sizeof(gid_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(gid_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(gid_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(gid_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else gid_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (gid_t) -1; } } else { gid_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (gid_t) -1; val = __Pyx_PyInt_As_gid_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to gid_t"); return (gid_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to gid_t"); return (gid_t) -1; } /* CIntFromPy */ static CYTHON_INLINE dev_t __Pyx_PyInt_As_dev_t(PyObject *x) { const dev_t neg_one = (dev_t) -1, const_zero = (dev_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(dev_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(dev_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (dev_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (dev_t) 0; case 1: __PYX_VERIFY_RETURN_INT(dev_t, digit, digits[0]) case 2: if (8 * sizeof(dev_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) >= 2 * PyLong_SHIFT) { return (dev_t) (((((dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0])); } } break; case 3: if (8 * sizeof(dev_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) >= 3 * PyLong_SHIFT) { return (dev_t) (((((((dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0])); } } break; case 4: if (8 * sizeof(dev_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) >= 4 * PyLong_SHIFT) { return (dev_t) (((((((((dev_t)digits[3]) << PyLong_SHIFT) | (dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (dev_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(dev_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(dev_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(dev_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(dev_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (dev_t) 0; case -1: __PYX_VERIFY_RETURN_INT(dev_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(dev_t, digit, +digits[0]) case -2: if (8 * sizeof(dev_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 2 * PyLong_SHIFT) { return (dev_t) (((dev_t)-1)*(((((dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; case 2: if (8 * sizeof(dev_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 2 * PyLong_SHIFT) { return (dev_t) ((((((dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; case -3: if (8 * sizeof(dev_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 3 * PyLong_SHIFT) { return (dev_t) (((dev_t)-1)*(((((((dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; case 3: if (8 * sizeof(dev_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 3 * PyLong_SHIFT) { return (dev_t) ((((((((dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; case -4: if (8 * sizeof(dev_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 4 * PyLong_SHIFT) { return (dev_t) (((dev_t)-1)*(((((((((dev_t)digits[3]) << PyLong_SHIFT) | (dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; case 4: if (8 * sizeof(dev_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(dev_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(dev_t) - 1 > 4 * PyLong_SHIFT) { return (dev_t) ((((((((((dev_t)digits[3]) << PyLong_SHIFT) | (dev_t)digits[2]) << PyLong_SHIFT) | (dev_t)digits[1]) << PyLong_SHIFT) | (dev_t)digits[0]))); } } break; } #endif if (sizeof(dev_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(dev_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(dev_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(dev_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else dev_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (dev_t) -1; } } else { dev_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (dev_t) -1; val = __Pyx_PyInt_As_dev_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to dev_t"); return (dev_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to dev_t"); return (dev_t) -1; } /* CIntFromPy */ static CYTHON_INLINE blkcnt_t __Pyx_PyInt_As_blkcnt_t(PyObject *x) { const blkcnt_t neg_one = (blkcnt_t) -1, const_zero = (blkcnt_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(blkcnt_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(blkcnt_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (blkcnt_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (blkcnt_t) 0; case 1: __PYX_VERIFY_RETURN_INT(blkcnt_t, digit, digits[0]) case 2: if (8 * sizeof(blkcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) >= 2 * PyLong_SHIFT) { return (blkcnt_t) (((((blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0])); } } break; case 3: if (8 * sizeof(blkcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) >= 3 * PyLong_SHIFT) { return (blkcnt_t) (((((((blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0])); } } break; case 4: if (8 * sizeof(blkcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) >= 4 * PyLong_SHIFT) { return (blkcnt_t) (((((((((blkcnt_t)digits[3]) << PyLong_SHIFT) | (blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (blkcnt_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(blkcnt_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(blkcnt_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(blkcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(blkcnt_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (blkcnt_t) 0; case -1: __PYX_VERIFY_RETURN_INT(blkcnt_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(blkcnt_t, digit, +digits[0]) case -2: if (8 * sizeof(blkcnt_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 2 * PyLong_SHIFT) { return (blkcnt_t) (((blkcnt_t)-1)*(((((blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; case 2: if (8 * sizeof(blkcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 2 * PyLong_SHIFT) { return (blkcnt_t) ((((((blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; case -3: if (8 * sizeof(blkcnt_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 3 * PyLong_SHIFT) { return (blkcnt_t) (((blkcnt_t)-1)*(((((((blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; case 3: if (8 * sizeof(blkcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 3 * PyLong_SHIFT) { return (blkcnt_t) ((((((((blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; case -4: if (8 * sizeof(blkcnt_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 4 * PyLong_SHIFT) { return (blkcnt_t) (((blkcnt_t)-1)*(((((((((blkcnt_t)digits[3]) << PyLong_SHIFT) | (blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; case 4: if (8 * sizeof(blkcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blkcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blkcnt_t) - 1 > 4 * PyLong_SHIFT) { return (blkcnt_t) ((((((((((blkcnt_t)digits[3]) << PyLong_SHIFT) | (blkcnt_t)digits[2]) << PyLong_SHIFT) | (blkcnt_t)digits[1]) << PyLong_SHIFT) | (blkcnt_t)digits[0]))); } } break; } #endif if (sizeof(blkcnt_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(blkcnt_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(blkcnt_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(blkcnt_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else blkcnt_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (blkcnt_t) -1; } } else { blkcnt_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (blkcnt_t) -1; val = __Pyx_PyInt_As_blkcnt_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to blkcnt_t"); return (blkcnt_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to blkcnt_t"); return (blkcnt_t) -1; } /* CIntFromPy */ static CYTHON_INLINE blksize_t __Pyx_PyInt_As_blksize_t(PyObject *x) { const blksize_t neg_one = (blksize_t) -1, const_zero = (blksize_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(blksize_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(blksize_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (blksize_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (blksize_t) 0; case 1: __PYX_VERIFY_RETURN_INT(blksize_t, digit, digits[0]) case 2: if (8 * sizeof(blksize_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) >= 2 * PyLong_SHIFT) { return (blksize_t) (((((blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0])); } } break; case 3: if (8 * sizeof(blksize_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) >= 3 * PyLong_SHIFT) { return (blksize_t) (((((((blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0])); } } break; case 4: if (8 * sizeof(blksize_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) >= 4 * PyLong_SHIFT) { return (blksize_t) (((((((((blksize_t)digits[3]) << PyLong_SHIFT) | (blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (blksize_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(blksize_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(blksize_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(blksize_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(blksize_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (blksize_t) 0; case -1: __PYX_VERIFY_RETURN_INT(blksize_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(blksize_t, digit, +digits[0]) case -2: if (8 * sizeof(blksize_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 2 * PyLong_SHIFT) { return (blksize_t) (((blksize_t)-1)*(((((blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; case 2: if (8 * sizeof(blksize_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 2 * PyLong_SHIFT) { return (blksize_t) ((((((blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; case -3: if (8 * sizeof(blksize_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 3 * PyLong_SHIFT) { return (blksize_t) (((blksize_t)-1)*(((((((blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; case 3: if (8 * sizeof(blksize_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 3 * PyLong_SHIFT) { return (blksize_t) ((((((((blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; case -4: if (8 * sizeof(blksize_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 4 * PyLong_SHIFT) { return (blksize_t) (((blksize_t)-1)*(((((((((blksize_t)digits[3]) << PyLong_SHIFT) | (blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; case 4: if (8 * sizeof(blksize_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(blksize_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(blksize_t) - 1 > 4 * PyLong_SHIFT) { return (blksize_t) ((((((((((blksize_t)digits[3]) << PyLong_SHIFT) | (blksize_t)digits[2]) << PyLong_SHIFT) | (blksize_t)digits[1]) << PyLong_SHIFT) | (blksize_t)digits[0]))); } } break; } #endif if (sizeof(blksize_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(blksize_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(blksize_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(blksize_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else blksize_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (blksize_t) -1; } } else { blksize_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (blksize_t) -1; val = __Pyx_PyInt_As_blksize_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to blksize_t"); return (blksize_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to blksize_t"); return (blksize_t) -1; } /* CIntFromPy */ static CYTHON_INLINE time_t __Pyx_PyInt_As_time_t(PyObject *x) { const time_t neg_one = (time_t) -1, const_zero = (time_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(time_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(time_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (time_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (time_t) 0; case 1: __PYX_VERIFY_RETURN_INT(time_t, digit, digits[0]) case 2: if (8 * sizeof(time_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) >= 2 * PyLong_SHIFT) { return (time_t) (((((time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0])); } } break; case 3: if (8 * sizeof(time_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) >= 3 * PyLong_SHIFT) { return (time_t) (((((((time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0])); } } break; case 4: if (8 * sizeof(time_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) >= 4 * PyLong_SHIFT) { return (time_t) (((((((((time_t)digits[3]) << PyLong_SHIFT) | (time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (time_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(time_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(time_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(time_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(time_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (time_t) 0; case -1: __PYX_VERIFY_RETURN_INT(time_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(time_t, digit, +digits[0]) case -2: if (8 * sizeof(time_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 2 * PyLong_SHIFT) { return (time_t) (((time_t)-1)*(((((time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; case 2: if (8 * sizeof(time_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 2 * PyLong_SHIFT) { return (time_t) ((((((time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; case -3: if (8 * sizeof(time_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 3 * PyLong_SHIFT) { return (time_t) (((time_t)-1)*(((((((time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; case 3: if (8 * sizeof(time_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 3 * PyLong_SHIFT) { return (time_t) ((((((((time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; case -4: if (8 * sizeof(time_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 4 * PyLong_SHIFT) { return (time_t) (((time_t)-1)*(((((((((time_t)digits[3]) << PyLong_SHIFT) | (time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; case 4: if (8 * sizeof(time_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(time_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(time_t) - 1 > 4 * PyLong_SHIFT) { return (time_t) ((((((((((time_t)digits[3]) << PyLong_SHIFT) | (time_t)digits[2]) << PyLong_SHIFT) | (time_t)digits[1]) << PyLong_SHIFT) | (time_t)digits[0]))); } } break; } #endif if (sizeof(time_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(time_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(time_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(time_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else time_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (time_t) -1; } } else { time_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (time_t) -1; val = __Pyx_PyInt_As_time_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to time_t"); return (time_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to time_t"); return (time_t) -1; } /* CIntFromPy */ static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) { const long neg_one = (long) -1, const_zero = (long) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(long) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (long) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (long) 0; case 1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0]) case 2: if (8 * sizeof(long) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) { return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])); } } break; case 3: if (8 * sizeof(long) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) { return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])); } } break; case 4: if (8 * sizeof(long) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) { return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (long) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(long) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (long) 0; case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(long, digit, +digits[0]) case -2: if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; case 2: if (8 * sizeof(long) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; case -3: if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; case 3: if (8 * sizeof(long) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; case -4: if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; case 4: if (8 * sizeof(long) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) { return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]))); } } break; } #endif if (sizeof(long) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else long val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (long) -1; } } else { long val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (long) -1; val = __Pyx_PyInt_As_long(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to long"); return (long) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to long"); return (long) -1; } /* CIntFromPy */ static CYTHON_INLINE fsblkcnt_t __Pyx_PyInt_As_fsblkcnt_t(PyObject *x) { const fsblkcnt_t neg_one = (fsblkcnt_t) -1, const_zero = (fsblkcnt_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(fsblkcnt_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (fsblkcnt_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fsblkcnt_t) 0; case 1: __PYX_VERIFY_RETURN_INT(fsblkcnt_t, digit, digits[0]) case 2: if (8 * sizeof(fsblkcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) >= 2 * PyLong_SHIFT) { return (fsblkcnt_t) (((((fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0])); } } break; case 3: if (8 * sizeof(fsblkcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) >= 3 * PyLong_SHIFT) { return (fsblkcnt_t) (((((((fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0])); } } break; case 4: if (8 * sizeof(fsblkcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) >= 4 * PyLong_SHIFT) { return (fsblkcnt_t) (((((((((fsblkcnt_t)digits[3]) << PyLong_SHIFT) | (fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (fsblkcnt_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(fsblkcnt_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(fsblkcnt_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fsblkcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fsblkcnt_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fsblkcnt_t) 0; case -1: __PYX_VERIFY_RETURN_INT(fsblkcnt_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(fsblkcnt_t, digit, +digits[0]) case -2: if (8 * sizeof(fsblkcnt_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 2 * PyLong_SHIFT) { return (fsblkcnt_t) (((fsblkcnt_t)-1)*(((((fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; case 2: if (8 * sizeof(fsblkcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 2 * PyLong_SHIFT) { return (fsblkcnt_t) ((((((fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; case -3: if (8 * sizeof(fsblkcnt_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 3 * PyLong_SHIFT) { return (fsblkcnt_t) (((fsblkcnt_t)-1)*(((((((fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; case 3: if (8 * sizeof(fsblkcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 3 * PyLong_SHIFT) { return (fsblkcnt_t) ((((((((fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; case -4: if (8 * sizeof(fsblkcnt_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 4 * PyLong_SHIFT) { return (fsblkcnt_t) (((fsblkcnt_t)-1)*(((((((((fsblkcnt_t)digits[3]) << PyLong_SHIFT) | (fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; case 4: if (8 * sizeof(fsblkcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsblkcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsblkcnt_t) - 1 > 4 * PyLong_SHIFT) { return (fsblkcnt_t) ((((((((((fsblkcnt_t)digits[3]) << PyLong_SHIFT) | (fsblkcnt_t)digits[2]) << PyLong_SHIFT) | (fsblkcnt_t)digits[1]) << PyLong_SHIFT) | (fsblkcnt_t)digits[0]))); } } break; } #endif if (sizeof(fsblkcnt_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(fsblkcnt_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fsblkcnt_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fsblkcnt_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else fsblkcnt_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (fsblkcnt_t) -1; } } else { fsblkcnt_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (fsblkcnt_t) -1; val = __Pyx_PyInt_As_fsblkcnt_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to fsblkcnt_t"); return (fsblkcnt_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to fsblkcnt_t"); return (fsblkcnt_t) -1; } /* CIntFromPy */ static CYTHON_INLINE fsfilcnt_t __Pyx_PyInt_As_fsfilcnt_t(PyObject *x) { const fsfilcnt_t neg_one = (fsfilcnt_t) -1, const_zero = (fsfilcnt_t) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(fsfilcnt_t) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (fsfilcnt_t) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fsfilcnt_t) 0; case 1: __PYX_VERIFY_RETURN_INT(fsfilcnt_t, digit, digits[0]) case 2: if (8 * sizeof(fsfilcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) >= 2 * PyLong_SHIFT) { return (fsfilcnt_t) (((((fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0])); } } break; case 3: if (8 * sizeof(fsfilcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) >= 3 * PyLong_SHIFT) { return (fsfilcnt_t) (((((((fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0])); } } break; case 4: if (8 * sizeof(fsfilcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) >= 4 * PyLong_SHIFT) { return (fsfilcnt_t) (((((((((fsfilcnt_t)digits[3]) << PyLong_SHIFT) | (fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (fsfilcnt_t) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(fsfilcnt_t) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(fsfilcnt_t, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fsfilcnt_t) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fsfilcnt_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (fsfilcnt_t) 0; case -1: __PYX_VERIFY_RETURN_INT(fsfilcnt_t, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(fsfilcnt_t, digit, +digits[0]) case -2: if (8 * sizeof(fsfilcnt_t) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 2 * PyLong_SHIFT) { return (fsfilcnt_t) (((fsfilcnt_t)-1)*(((((fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; case 2: if (8 * sizeof(fsfilcnt_t) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 2 * PyLong_SHIFT) { return (fsfilcnt_t) ((((((fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; case -3: if (8 * sizeof(fsfilcnt_t) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 3 * PyLong_SHIFT) { return (fsfilcnt_t) (((fsfilcnt_t)-1)*(((((((fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; case 3: if (8 * sizeof(fsfilcnt_t) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 3 * PyLong_SHIFT) { return (fsfilcnt_t) ((((((((fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; case -4: if (8 * sizeof(fsfilcnt_t) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 4 * PyLong_SHIFT) { return (fsfilcnt_t) (((fsfilcnt_t)-1)*(((((((((fsfilcnt_t)digits[3]) << PyLong_SHIFT) | (fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; case 4: if (8 * sizeof(fsfilcnt_t) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(fsfilcnt_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(fsfilcnt_t) - 1 > 4 * PyLong_SHIFT) { return (fsfilcnt_t) ((((((((((fsfilcnt_t)digits[3]) << PyLong_SHIFT) | (fsfilcnt_t)digits[2]) << PyLong_SHIFT) | (fsfilcnt_t)digits[1]) << PyLong_SHIFT) | (fsfilcnt_t)digits[0]))); } } break; } #endif if (sizeof(fsfilcnt_t) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(fsfilcnt_t, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(fsfilcnt_t) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(fsfilcnt_t, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else fsfilcnt_t val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (fsfilcnt_t) -1; } } else { fsfilcnt_t val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (fsfilcnt_t) -1; val = __Pyx_PyInt_As_fsfilcnt_t(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to fsfilcnt_t"); return (fsfilcnt_t) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to fsfilcnt_t"); return (fsfilcnt_t) -1; } /* CIntFromPy */ static CYTHON_INLINE char __Pyx_PyInt_As_char(PyObject *x) { const char neg_one = (char) -1, const_zero = (char) 0; const int is_unsigned = neg_one > const_zero; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_Check(x))) { if (sizeof(char) < sizeof(long)) { __PYX_VERIFY_RETURN_INT(char, long, PyInt_AS_LONG(x)) } else { long val = PyInt_AS_LONG(x); if (is_unsigned && unlikely(val < 0)) { goto raise_neg_overflow; } return (char) val; } } else #endif if (likely(PyLong_Check(x))) { if (is_unsigned) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (char) 0; case 1: __PYX_VERIFY_RETURN_INT(char, digit, digits[0]) case 2: if (8 * sizeof(char) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) >= 2 * PyLong_SHIFT) { return (char) (((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0])); } } break; case 3: if (8 * sizeof(char) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) >= 3 * PyLong_SHIFT) { return (char) (((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])); } } break; case 4: if (8 * sizeof(char) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) >= 4 * PyLong_SHIFT) { return (char) (((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0])); } } break; } #endif #if CYTHON_COMPILING_IN_CPYTHON if (unlikely(Py_SIZE(x) < 0)) { goto raise_neg_overflow; } #else { int result = PyObject_RichCompareBool(x, Py_False, Py_LT); if (unlikely(result < 0)) return (char) -1; if (unlikely(result == 1)) goto raise_neg_overflow; } #endif if (sizeof(char) <= sizeof(unsigned long)) { __PYX_VERIFY_RETURN_INT_EXC(char, unsigned long, PyLong_AsUnsignedLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(char) <= sizeof(unsigned PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(char, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x)) #endif } } else { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)x)->ob_digit; switch (Py_SIZE(x)) { case 0: return (char) 0; case -1: __PYX_VERIFY_RETURN_INT(char, sdigit, (sdigit) (-(sdigit)digits[0])) case 1: __PYX_VERIFY_RETURN_INT(char, digit, +digits[0]) case -2: if (8 * sizeof(char) - 1 > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 2 * PyLong_SHIFT) { return (char) (((char)-1)*(((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; case 2: if (8 * sizeof(char) > 1 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 2 * PyLong_SHIFT) { return (char) ((((((char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; case -3: if (8 * sizeof(char) - 1 > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 3 * PyLong_SHIFT) { return (char) (((char)-1)*(((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; case 3: if (8 * sizeof(char) > 2 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 3 * PyLong_SHIFT) { return (char) ((((((((char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; case -4: if (8 * sizeof(char) - 1 > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 4 * PyLong_SHIFT) { return (char) (((char)-1)*(((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; case 4: if (8 * sizeof(char) > 3 * PyLong_SHIFT) { if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) { __PYX_VERIFY_RETURN_INT(char, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0]))) } else if (8 * sizeof(char) - 1 > 4 * PyLong_SHIFT) { return (char) ((((((((((char)digits[3]) << PyLong_SHIFT) | (char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (char)digits[0]))); } } break; } #endif if (sizeof(char) <= sizeof(long)) { __PYX_VERIFY_RETURN_INT_EXC(char, long, PyLong_AsLong(x)) #ifdef HAVE_LONG_LONG } else if (sizeof(char) <= sizeof(PY_LONG_LONG)) { __PYX_VERIFY_RETURN_INT_EXC(char, PY_LONG_LONG, PyLong_AsLongLong(x)) #endif } } { #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray) PyErr_SetString(PyExc_RuntimeError, "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers"); #else char val; PyObject *v = __Pyx_PyNumber_IntOrLong(x); #if PY_MAJOR_VERSION < 3 if (likely(v) && !PyLong_Check(v)) { PyObject *tmp = v; v = PyNumber_Long(tmp); Py_DECREF(tmp); } #endif if (likely(v)) { int one = 1; int is_little = (int)*(unsigned char *)&one; unsigned char *bytes = (unsigned char *)&val; int ret = _PyLong_AsByteArray((PyLongObject *)v, bytes, sizeof(val), is_little, !is_unsigned); Py_DECREF(v); if (likely(!ret)) return val; } #endif return (char) -1; } } else { char val; PyObject *tmp = __Pyx_PyNumber_IntOrLong(x); if (!tmp) return (char) -1; val = __Pyx_PyInt_As_char(tmp); Py_DECREF(tmp); return val; } raise_overflow: PyErr_SetString(PyExc_OverflowError, "value too large to convert to char"); return (char) -1; raise_neg_overflow: PyErr_SetString(PyExc_OverflowError, "can't convert negative value to char"); return (char) -1; } /* CheckBinaryVersion */ static int __Pyx_check_binary_version(void) { char ctversion[4], rtversion[4]; PyOS_snprintf(ctversion, 4, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION); PyOS_snprintf(rtversion, 4, "%s", Py_GetVersion()); if (ctversion[0] != rtversion[0] || ctversion[2] != rtversion[2]) { char message[200]; PyOS_snprintf(message, sizeof(message), "compiletime version %s of module '%.100s' " "does not match runtime version %s", ctversion, __Pyx_MODULE_NAME, rtversion); return PyErr_WarnEx(NULL, message, 1); } return 0; } /* ModuleImport */ #ifndef __PYX_HAVE_RT_ImportModule #define __PYX_HAVE_RT_ImportModule static PyObject *__Pyx_ImportModule(const char *name) { PyObject *py_name = 0; PyObject *py_module = 0; py_name = __Pyx_PyIdentifier_FromString(name); if (!py_name) goto bad; py_module = PyImport_Import(py_name); Py_DECREF(py_name); return py_module; bad: Py_XDECREF(py_name); return 0; } #endif /* TypeImport */ #ifndef __PYX_HAVE_RT_ImportType #define __PYX_HAVE_RT_ImportType static PyTypeObject *__Pyx_ImportType(const char *module_name, const char *class_name, size_t size, int strict) { PyObject *py_module = 0; PyObject *result = 0; PyObject *py_name = 0; char warning[200]; Py_ssize_t basicsize; #ifdef Py_LIMITED_API PyObject *py_basicsize; #endif py_module = __Pyx_ImportModule(module_name); if (!py_module) goto bad; py_name = __Pyx_PyIdentifier_FromString(class_name); if (!py_name) goto bad; result = PyObject_GetAttr(py_module, py_name); Py_DECREF(py_name); py_name = 0; Py_DECREF(py_module); py_module = 0; if (!result) goto bad; if (!PyType_Check(result)) { PyErr_Format(PyExc_TypeError, "%.200s.%.200s is not a type object", module_name, class_name); goto bad; } #ifndef Py_LIMITED_API basicsize = ((PyTypeObject *)result)->tp_basicsize; #else py_basicsize = PyObject_GetAttrString(result, "__basicsize__"); if (!py_basicsize) goto bad; basicsize = PyLong_AsSsize_t(py_basicsize); Py_DECREF(py_basicsize); py_basicsize = 0; if (basicsize == (Py_ssize_t)-1 && PyErr_Occurred()) goto bad; #endif if (!strict && (size_t)basicsize > size) { PyOS_snprintf(warning, sizeof(warning), "%s.%s size changed, may indicate binary incompatibility. Expected %zd, got %zd", module_name, class_name, basicsize, size); if (PyErr_WarnEx(NULL, warning, 0) < 0) goto bad; } else if ((size_t)basicsize != size) { PyErr_Format(PyExc_ValueError, "%.200s.%.200s has the wrong size, try recompiling. Expected %zd, got %zd", module_name, class_name, basicsize, size); goto bad; } return (PyTypeObject *)result; bad: Py_XDECREF(py_module); Py_XDECREF(result); return NULL; } #endif /* InitStrings */ static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) { while (t->p) { #if PY_MAJOR_VERSION < 3 if (t->is_unicode) { *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL); } else if (t->intern) { *t->p = PyString_InternFromString(t->s); } else { *t->p = PyString_FromStringAndSize(t->s, t->n - 1); } #else if (t->is_unicode | t->is_str) { if (t->intern) { *t->p = PyUnicode_InternFromString(t->s); } else if (t->encoding) { *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL); } else { *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1); } } else { *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1); } #endif if (!*t->p) return -1; ++t; } return 0; } static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) { return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str)); } static CYTHON_INLINE char* __Pyx_PyObject_AsString(PyObject* o) { Py_ssize_t ignore; return __Pyx_PyObject_AsStringAndSize(o, &ignore); } static CYTHON_INLINE char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) { #if CYTHON_COMPILING_IN_CPYTHON && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT) if ( #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII __Pyx_sys_getdefaultencoding_not_ascii && #endif PyUnicode_Check(o)) { #if PY_VERSION_HEX < 0x03030000 char* defenc_c; PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL); if (!defenc) return NULL; defenc_c = PyBytes_AS_STRING(defenc); #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII { char* end = defenc_c + PyBytes_GET_SIZE(defenc); char* c; for (c = defenc_c; c < end; c++) { if ((unsigned char) (*c) >= 128) { PyUnicode_AsASCIIString(o); return NULL; } } } #endif *length = PyBytes_GET_SIZE(defenc); return defenc_c; #else if (__Pyx_PyUnicode_READY(o) == -1) return NULL; #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII if (PyUnicode_IS_ASCII(o)) { *length = PyUnicode_GET_LENGTH(o); return PyUnicode_AsUTF8(o); } else { PyUnicode_AsASCIIString(o); return NULL; } #else return PyUnicode_AsUTF8AndSize(o, length); #endif #endif } else #endif #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE)) if (PyByteArray_Check(o)) { *length = PyByteArray_GET_SIZE(o); return PyByteArray_AS_STRING(o); } else #endif { char* result; int r = PyBytes_AsStringAndSize(o, &result, length); if (unlikely(r < 0)) { return NULL; } else { return result; } } } static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) { int is_true = x == Py_True; if (is_true | (x == Py_False) | (x == Py_None)) return is_true; else return PyObject_IsTrue(x); } static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) { #if CYTHON_USE_TYPE_SLOTS PyNumberMethods *m; #endif const char *name = NULL; PyObject *res = NULL; #if PY_MAJOR_VERSION < 3 if (PyInt_Check(x) || PyLong_Check(x)) #else if (PyLong_Check(x)) #endif return __Pyx_NewRef(x); #if CYTHON_USE_TYPE_SLOTS m = Py_TYPE(x)->tp_as_number; #if PY_MAJOR_VERSION < 3 if (m && m->nb_int) { name = "int"; res = PyNumber_Int(x); } else if (m && m->nb_long) { name = "long"; res = PyNumber_Long(x); } #else if (m && m->nb_int) { name = "int"; res = PyNumber_Long(x); } #endif #else res = PyNumber_Int(x); #endif if (res) { #if PY_MAJOR_VERSION < 3 if (!PyInt_Check(res) && !PyLong_Check(res)) { #else if (!PyLong_Check(res)) { #endif PyErr_Format(PyExc_TypeError, "__%.4s__ returned non-%.4s (type %.200s)", name, name, Py_TYPE(res)->tp_name); Py_DECREF(res); return NULL; } } else if (!PyErr_Occurred()) { PyErr_SetString(PyExc_TypeError, "an integer is required"); } return res; } static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) { Py_ssize_t ival; PyObject *x; #if PY_MAJOR_VERSION < 3 if (likely(PyInt_CheckExact(b))) { if (sizeof(Py_ssize_t) >= sizeof(long)) return PyInt_AS_LONG(b); else return PyInt_AsSsize_t(x); } #endif if (likely(PyLong_CheckExact(b))) { #if CYTHON_USE_PYLONG_INTERNALS const digit* digits = ((PyLongObject*)b)->ob_digit; const Py_ssize_t size = Py_SIZE(b); if (likely(__Pyx_sst_abs(size) <= 1)) { ival = likely(size) ? digits[0] : 0; if (size == -1) ival = -ival; return ival; } else { switch (size) { case 2: if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) { return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; case -2: if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) { return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; case 3: if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) { return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; case -3: if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) { return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; case 4: if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) { return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; case -4: if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) { return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])); } break; } } #endif return PyLong_AsSsize_t(b); } x = PyNumber_Index(b); if (!x) return -1; ival = PyInt_AsSsize_t(x); Py_DECREF(x); return ival; } static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) { return PyInt_FromSize_t(ival); } #endif /* Py_PYTHON_H */ llfuse-1.3.3/src/misc.pxi0000664000175000017500000005173713202301227016745 0ustar nikrationikratio00000000000000''' misc.pxi This file defines various functions that are used internally by LLFUSE. It is included by llfuse.pyx. Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' cdef int handle_exc(fuse_req_t req): '''Try to call fuse_reply_err and terminate main loop''' cdef int res global exc_info res = pthread_mutex_lock(&exc_info_mutex) if res != 0: log.error('pthread_mutex_lock failed with %s', strerror(res)) if not exc_info: exc_info = sys.exc_info() log.info('handler raised %s exception (%s), terminating main loop.', exc_info[0], exc_info[1]) fuse_session_exit(session) else: log.exception('Only one exception can be re-raised in `llfuse.main`, ' 'the following exception will be lost') pthread_mutex_unlock(&exc_info_mutex) if res != 0: log.error('pthread_mutex_ulock failed with %s', strerror(res)) if req is NULL: return 0 else: return fuse_reply_err(req, errno.EIO) cdef object get_request_context(fuse_req_t req): '''Get RequestContext() object''' cdef const_fuse_ctx* context cdef RequestContext ctx context = fuse_req_ctx(req) ctx = RequestContext.__new__(RequestContext) ctx.pid = context.pid ctx.uid = context.uid ctx.gid = context.gid ctx.umask = context.umask return ctx cdef void init_fuse_ops(): '''Initialize fuse_lowlevel_ops structure''' string.memset(&fuse_ops, 0, sizeof(fuse_lowlevel_ops)) fuse_ops.init = fuse_init fuse_ops.destroy = fuse_destroy fuse_ops.lookup = fuse_lookup fuse_ops.forget = fuse_forget fuse_ops.getattr = fuse_getattr fuse_ops.setattr = fuse_setattr fuse_ops.readlink = fuse_readlink fuse_ops.mknod = fuse_mknod fuse_ops.mkdir = fuse_mkdir fuse_ops.unlink = fuse_unlink fuse_ops.rmdir = fuse_rmdir fuse_ops.symlink = fuse_symlink fuse_ops.rename = fuse_rename fuse_ops.link = fuse_link fuse_ops.open = fuse_open fuse_ops.read = fuse_read fuse_ops.write = fuse_write fuse_ops.flush = fuse_flush fuse_ops.release = fuse_release fuse_ops.fsync = fuse_fsync fuse_ops.opendir = fuse_opendir fuse_ops.readdir = fuse_readdir fuse_ops.releasedir = fuse_releasedir fuse_ops.fsyncdir = fuse_fsyncdir fuse_ops.statfs = fuse_statfs ASSIGN_DARWIN(fuse_ops.setxattr, &fuse_setxattr_darwin) ASSIGN_DARWIN(fuse_ops.getxattr, &fuse_getxattr_darwin) ASSIGN_NOT_DARWIN(fuse_ops.setxattr, &fuse_setxattr) ASSIGN_NOT_DARWIN(fuse_ops.getxattr, &fuse_getxattr) fuse_ops.listxattr = fuse_listxattr fuse_ops.removexattr = fuse_removexattr fuse_ops.access = fuse_access fuse_ops.create = fuse_create fuse_ops.forget_multi = fuse_forget_multi fuse_ops.write_buf = fuse_write_buf cdef make_fuse_args(args, fuse_args* f_args): cdef char* arg cdef int i cdef ssize_t size_s cdef size_t size args_new = [ b'Python-LLFUSE' ] for el in args: args_new.append(b'-o') args_new.append(el.encode('us-ascii')) args = args_new f_args.argc = len(args) if f_args.argc == 0: f_args.argv = NULL return f_args.allocated = 1 f_args.argv = stdlib.calloc( f_args.argc, sizeof(char*)) if f_args.argv is NULL: cpython.exc.PyErr_NoMemory() try: for (i, el) in enumerate(args): PyBytes_AsStringAndSize(el, &arg, &size_s) size = size_s # guaranteed positive f_args.argv[i] = stdlib.malloc((size+1)*sizeof(char)) if f_args.argv[i] is NULL: cpython.exc.PyErr_NoMemory() string.strncpy(f_args.argv[i], arg, size+1) except: for i in range(f_args.argc): # Freeing a NULL pointer (if this element has not been allocated # yet) is fine. stdlib.free(f_args.argv[i]) stdlib.free(f_args.argv) raise cdef class Lock: ''' This is the class of lock itself as well as a context manager to execute code while the global lock is being held. ''' def __init__(self): raise TypeError('You should not instantiate this class, use the ' 'provided instance instead.') def acquire(self, timeout=None): '''Acquire global lock If *timeout* is not None, and the lock could not be acquired after waiting for *timeout* seconds, return False. Otherwise return True. ''' cdef int ret cdef int timeout_c if timeout is None: timeout_c = 0 else: timeout_c = timeout with nogil: ret = acquire(timeout_c) if ret == 0: return True elif ret == ETIMEDOUT and timeout != 0: return False elif ret == EDEADLK: raise RuntimeError("Global lock cannot be acquired more than once") elif ret == EPROTO: raise RuntimeError("Lock still taken after receiving unlock notification") elif ret == EINVAL: raise RuntimeError("Lock not initialized") else: raise RuntimeError(strerror(ret)) def release(self): '''Release global lock''' cdef int ret with nogil: ret = release() if ret == 0: return elif ret == EPERM: raise RuntimeError("Lock can only be released by the holding thread") elif ret == EINVAL: raise RuntimeError("Lock not initialized") else: raise RuntimeError(strerror(ret)) def yield_(self, count=1): '''Yield global lock to a different thread A call to `~Lock.yield_` is roughly similar to:: for i in range(count): if no_threads_waiting_for(lock): break lock.release() lock.acquire() However, when using `~Lock.yield_` it is guaranteed that the lock will actually be passed to a different thread (the above pseude-code may result in the same thread re-acquiring the lock *count* times). ''' cdef int ret cdef int count_c count_c = count with nogil: ret = c_yield(count_c) if ret == 0: return elif ret == EPERM: raise RuntimeError("Lock can only be released by the holding thread") elif ret == EPROTO: raise RuntimeError("Lock still taken after receiving unlock notification") elif ret == ENOMSG: raise RuntimeError("Other thread didn't take lock") elif ret == EINVAL: raise RuntimeError("Lock not initialized") else: raise RuntimeError(strerror(ret)) def __enter__(self): self.acquire() def __exit__(self, exc_type, exc_val, exc_tb): self.release() def __getstate__(self): raise PicklingError("Lock instances can't be pickled") cdef class NoLockManager: '''Context manager to execute code while the global lock is released''' def __init__(self): raise TypeError('You should not instantiate this class, use the ' 'provided instance instead.') def __enter__ (self): lock.release() def __exit__(self, *a): lock.acquire() def __getstate__(self): raise PicklingError("NoLockManager instances can't be pickled") def _notify_loop(): '''Read notifications from queue and send to FUSE kernel module''' cdef ssize_t len_ cdef char *cname cdef NotifyRequest req while True: req = _notify_queue.get() if req is None: return if req.kind == NOTIFY_INVAL_INODE: if req.attr_only: with nogil: fuse_lowlevel_notify_inval_inode(channel, req.ino, -1, 0) else: with nogil: fuse_lowlevel_notify_inval_inode(channel, req.ino, 0, 0) elif req.kind == NOTIFY_INVAL_ENTRY: PyBytes_AsStringAndSize(req.name, &cname, &len_) with nogil: # len_ is guaranteed positive fuse_lowlevel_notify_inval_entry(channel, req.ino, cname, len_) else: raise RuntimeError("Weird request kind received: %d", req.kind) cdef str2bytes(s): '''Convert *s* to bytes Under Python 2.x, just returns *s*. Under Python 3.x, converts to file system encoding using surrogateescape. ''' if PY_MAJOR_VERSION < 3: return s else: return s.encode(fse, 'surrogateescape') cdef bytes2str(s): '''Convert *s* to str Under Python 2.x, just returns *s*. Under Python 3.x, converts from file system encoding using surrogateescape. ''' if PY_MAJOR_VERSION < 3: return s else: return s.decode(fse, 'surrogateescape') cdef strerror(int errno): try: return os.strerror(errno) except ValueError: return 'errno: %d' % errno @cython.freelist(10) cdef class RequestContext: ''' Instances of this class are passed to some `Operations` methods to provide information about the caller of the syscall that initiated the request. ''' cdef readonly uid_t uid cdef readonly pid_t pid cdef readonly gid_t gid cdef readonly mode_t umask def __getstate__(self): raise PicklingError("RequestContext instances can't be pickled") @cython.freelist(10) cdef class SetattrFields: ''' `SetattrFields` instances are passed to the `~Operations.setattr` handler to specify which attributes should be updated. ''' cdef readonly object update_atime cdef readonly object update_mtime cdef readonly object update_mode cdef readonly object update_uid cdef readonly object update_gid cdef readonly object update_size def __cinit__(self): self.update_atime = False self.update_mtime = False self.update_mode = False self.update_uid = False self.update_gid = False self.update_size = False def __getstate__(self): raise PicklingError("SetattrFields instances can't be pickled") @cython.freelist(30) cdef class EntryAttributes: ''' Instances of this class store attributes of directory entries. Most of the attributes correspond to the elements of the ``stat`` C struct as returned by e.g. ``fstat`` and should be self-explanatory. ''' # Attributes are documented in rst/data.rst cdef fuse_entry_param fuse_param cdef struct_stat *attr def __cinit__(self): string.memset(&self.fuse_param, 0, sizeof(fuse_entry_param)) self.attr = &self.fuse_param.attr self.fuse_param.generation = 0 self.fuse_param.entry_timeout = 300 self.fuse_param.attr_timeout = 300 self.attr.st_mode = S_IFREG self.attr.st_blksize = 4096 self.attr.st_nlink = 1 @property def st_ino(self): return self.fuse_param.ino @st_ino.setter def st_ino(self, val): self.fuse_param.ino = val self.attr.st_ino = val @property def generation(self): '''The inode generation number''' return self.fuse_param.generation @generation.setter def generation(self, val): self.fuse_param.generation = val @property def attr_timeout(self): '''Validity timeout for the attributes of the directory entry Floating point numbers may be used. Units are seconds. ''' return self.fuse_param.attr_timeout @attr_timeout.setter def attr_timeout(self, val): self.fuse_param.attr_timeout = val @property def entry_timeout(self): '''Validity timeout for the name/existence of the directory entry Floating point numbers may be used. Units are seconds. ''' return self.fuse_param.entry_timeout @entry_timeout.setter def entry_timeout(self, val): self.fuse_param.entry_timeout = val @property def st_mode(self): return self.attr.st_mode @st_mode.setter def st_mode(self, val): self.attr.st_mode = val @property def st_nlink(self): return self.attr.st_nlink @st_nlink.setter def st_nlink(self, val): self.attr.st_nlink = val @property def st_uid(self): return self.attr.st_uid @st_uid.setter def st_uid(self, val): self.attr.st_uid = val @property def st_gid(self): return self.attr.st_gid @st_gid.setter def st_gid(self, val): self.attr.st_gid = val @property def st_rdev(self): return self.attr.st_rdev @st_rdev.setter def st_rdev(self, val): self.attr.st_rdev = val @property def st_size(self): return self.attr.st_size @st_size.setter def st_size(self, val): self.attr.st_size = val @property def st_blocks(self): return self.attr.st_blocks @st_blocks.setter def st_blocks(self, val): self.attr.st_blocks = val @property def st_blksize(self): return self.attr.st_blksize @st_blksize.setter def st_blksize(self, val): self.attr.st_blksize = val @property def st_atime_ns(self): '''Time of last access in (integer) nanoseconds''' return (int(self.attr.st_atime) * 10**9 + GET_ATIME_NS(self.attr)) @st_atime_ns.setter def st_atime_ns(self, val): self.attr.st_atime = val / 10**9 SET_ATIME_NS(self.attr, val % 10**9) @property def st_mtime_ns(self): '''Time of last modification in (integer) nanoseconds''' return (int(self.attr.st_mtime) * 10**9 + GET_MTIME_NS(self.attr)) @st_mtime_ns.setter def st_mtime_ns(self, val): self.attr.st_mtime = val / 10**9 SET_MTIME_NS(self.attr, val % 10**9) @property def st_ctime_ns(self): '''Time of last inode modification in (integer) nanoseconds''' return (int(self.attr.st_ctime) * 10**9 + GET_CTIME_NS(self.attr)) @st_ctime_ns.setter def st_ctime_ns(self, val): self.attr.st_ctime = val / 10**9 SET_CTIME_NS(self.attr, val % 10**9) @property def st_birthtime_ns(self): '''Time of inode creation in (integer) nanoseconds. Only available under BSD and OS X. Will be zero on Linux. ''' # Use C macro to prevent compiler error on Linux # (where st_birthtime does not exist) return int(GET_BIRTHTIME(self.attr) * 10**9 + GET_BIRTHTIME_NS(self.attr)) @st_birthtime_ns.setter def st_birthtime_ns(self, val): # Use C macro to prevent compiler error on Linux # (where st_birthtime does not exist) SET_BIRTHTIME(self.attr, val / 10**9) SET_BIRTHTIME_NS(self.attr, val % 10**9) # Pickling and copy support def __getstate__(self): state = dict() for k in ('st_ino', 'generation', 'entry_timeout', 'attr_timeout', 'st_mode', 'st_nlink', 'st_uid', 'st_gid', 'st_rdev', 'st_size', 'st_blksize', 'st_blocks', 'st_atime_ns', 'st_ctime_ns', 'st_mtime_ns', 'st_birthtime_ns'): state[k] = getattr(self, k) return state def __setstate__(self, state): for (k,v) in state.items(): setattr(self, k, v) @cython.freelist(1) cdef class StatvfsData: ''' Instances of this class store information about the file system. The attributes correspond to the elements of the ``statvfs`` struct, see :manpage:`statvfs(2)` for details. ''' cdef statvfs stat def __cinit__(self): string.memset(&self.stat, 0, sizeof(statvfs)) @property def f_bsize(self): return self.stat.f_bsize @f_bsize.setter def f_bsize(self, val): self.stat.f_bsize = val @property def f_frsize(self): return self.stat.f_frsize @f_frsize.setter def f_frsize(self, val): self.stat.f_frsize = val @property def f_blocks(self): return self.stat.f_blocks @f_blocks.setter def f_blocks(self, val): self.stat.f_blocks = val @property def f_bfree(self): return self.stat.f_bfree @f_bfree.setter def f_bfree(self, val): self.stat.f_bfree = val @property def f_bavail(self): return self.stat.f_bavail @f_bavail.setter def f_bavail(self, val): self.stat.f_bavail = val @property def f_files(self): return self.stat.f_files @f_files.setter def f_files(self, val): self.stat.f_files = val @property def f_ffree(self): return self.stat.f_ffree @f_ffree.setter def f_ffree(self, val): self.stat.f_ffree = val @property def f_favail(self): return self.stat.f_favail @f_favail.setter def f_favail(self, val): self.stat.f_favail = val @property def f_namemax(self): return self.stat.f_namemax @f_namemax.setter def f_namemax(self, val): self.stat.f_namemax = val # Pickling and copy support def __getstate__(self): state = dict() for k in ('f_bsize', 'f_frsize', 'f_blocks', 'f_bfree', 'f_bavail', 'f_files', 'f_ffree', 'f_favail', 'f_namemax'): state[k] = getattr(self, k) return state def __setstate__(self, state): for (k,v) in state.items(): setattr(self, k, v) # As of Cython 0.23.1, @cython.freelist cannot be used for # classes that derive from a builtin type. cdef class FUSEError(Exception): ''' This exception may be raised by request handlers to indicate that the requested operation could not be carried out. The system call that resulted in the request (if any) will then fail with error code *errno_*. ''' # If we call this variable "errno", we will get syntax errors # during C compilation (maybe something else declares errno as # a macro?) cdef readonly int errno_ @property def errno(self): '''Error code to return to client process''' return self.errno_ def __cinit__(self, errno): self.errno_ = errno def __str__(self): return strerror(self.errno_) @cython.freelist(300) cdef class NotifyRequest: cdef fuse_ino_t ino cdef char attr_only cdef object name cdef int kind cdef PyBytes_from_bufvec(fuse_bufvec *src): cdef fuse_bufvec dst cdef size_t len_ cdef ssize_t res len_ = fuse_buf_size(src) - src.off if len_ > PY_SSIZE_T_MAX: raise OverflowError('Value too long to convert to Python') buf = PyBytes_FromStringAndSize(NULL, len_) dst.count = 1 dst.idx = 0 dst.off = 0 dst.buf[0].mem = PyBytes_AS_STRING(buf) dst.buf[0].size = len_ dst.buf[0].flags = 0 res = fuse_buf_copy(&dst, src, 0) if res < 0: raise OSError(errno.errno, 'fuse_buf_copy failed with ' + strerror(errno.errno)) elif res < len_: # This is expected to be rare return buf[:res] else: return buf cdef class VoidPtrCapsule: cdef void* ptr cdef free_p(VoidPtrCapsule cap): stdlib.free(cap.ptr) cdef inline encap_ptr(void *ptr): cdef VoidPtrCapsule cap cap = VoidPtrCapsule.__new__(VoidPtrCapsule) cap.ptr = ptr return cap cdef void signal_handler(int sig, siginfo_t *si, void* ctx) nogil: global exit_reason if session != NULL: fuse_session_exit(session) exit_reason = sig cdef void do_nothing(int sig, siginfo_t *si, void* ctx) nogil: pass cdef int sigaction_p(int sig, sigaction_t *sa, sigaction_t *old_sa) except -1: cdef int res res = sigaction(sig, sa, old_sa) if res != 0: raise OSError(errno.errno, 'sigaction failed with ' + strerror(errno.errno)) return 0 cdef sigaction_t sa_backup[5] cdef set_signal_handlers(): cdef sigaction_t sa sigemptyset(&sa.sa_mask) sa.sa_sigaction = &signal_handler sa.sa_flags = SA_SIGINFO sigaction_p(signal.SIGTERM, &sa, &sa_backup[0]) sigaction_p(signal.SIGINT, &sa, &sa_backup[1]) sigaction_p(signal.SIGHUP, &sa, &sa_backup[2]) # This is used to interrupt system calls without # doing anything else. sa.sa_sigaction = &do_nothing sa.sa_flags = SA_SIGINFO sigaction_p(signal.SIGUSR1, &sa, &sa_backup[3]) sa.sa_handler = signal.SIG_IGN sa.sa_flags = 0 sigaction_p(signal.SIGPIPE, &sa, &sa_backup[4]) cdef restore_signal_handlers(): sigaction_p(signal.SIGTERM, &sa_backup[0], NULL) sigaction_p(signal.SIGINT, &sa_backup[1], NULL) sigaction_p(signal.SIGHUP, &sa_backup[2], NULL) sigaction_p(signal.SIGUSR1, &sa_backup[3], NULL) sigaction_p(signal.SIGPIPE, &sa_backup[4], NULL) cdef void* calloc_or_raise(size_t nmemb, size_t size) except NULL: cdef void* mem mem = stdlib.calloc(nmemb, size) if mem is NULL: raise MemoryError() return mem llfuse-1.3.3/src/macros.c0000664000175000017500000000362413202301227016710 0ustar nikrationikratio00000000000000/* macros.c - Pre-processor macros Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. */ /* * Macros to access the nanosecond attributes in struct stat in a * platform independent way. Stolen from fuse_misc.h. */ #if PLATFORM == PLATFORM_LINUX #define GET_ATIME_NS(stbuf) ((stbuf)->st_atim.tv_nsec) #define GET_CTIME_NS(stbuf) ((stbuf)->st_ctim.tv_nsec) #define GET_MTIME_NS(stbuf) ((stbuf)->st_mtim.tv_nsec) #define SET_ATIME_NS(stbuf, val) (stbuf)->st_atim.tv_nsec = (val) #define SET_CTIME_NS(stbuf, val) (stbuf)->st_ctim.tv_nsec = (val) #define SET_MTIME_NS(stbuf, val) (stbuf)->st_mtim.tv_nsec = (val) #define GET_BIRTHTIME_NS(stbuf) (0) #define GET_BIRTHTIME(stbuf) (0) #define SET_BIRTHTIME_NS(stbuf, val) do {} while (0) #define SET_BIRTHTIME(stbuf, val) do {} while (0) /* BSD and OS-X */ #else #define GET_BIRTHTIME(stbuf) ((stbuf)->st_birthtime) #define SET_BIRTHTIME(stbuf, val) ((stbuf)->st_birthtime = (val)) #define GET_ATIME_NS(stbuf) ((stbuf)->st_atimespec.tv_nsec) #define GET_CTIME_NS(stbuf) ((stbuf)->st_ctimespec.tv_nsec) #define GET_MTIME_NS(stbuf) ((stbuf)->st_mtimespec.tv_nsec) #define GET_BIRTHTIME_NS(stbuf) ((stbuf)->st_birthtimespec.tv_nsec) #define SET_ATIME_NS(stbuf, val) ((stbuf)->st_atimespec.tv_nsec = (val)) #define SET_CTIME_NS(stbuf, val) ((stbuf)->st_ctimespec.tv_nsec = (val)) #define SET_MTIME_NS(stbuf, val) ((stbuf)->st_mtimespec.tv_nsec = (val)) #define SET_BIRTHTIME_NS(stbuf, val) ((stbuf)->st_birthtimespec.tv_nsec = (val)) #endif #if PLATFORM == PLATFORM_LINUX || PLATFORM == PLATFORM_BSD #define ASSIGN_DARWIN(x,y) #define ASSIGN_NOT_DARWIN(x,y) ((x) = (y)) #elif PLATFORM == PLATFORM_DARWIN #define ASSIGN_DARWIN(x,y) ((x) = (y)) #define ASSIGN_NOT_DARWIN(x,y) #else #error This should not happen #endif /* * Constants */ #define NOTIFY_INVAL_INODE 1 #define NOTIFY_INVAL_ENTRY 2 llfuse-1.3.3/src/llfuse.h0000664000175000017500000000163412654245112016734 0ustar nikrationikratio00000000000000/* llfuse.h Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. */ #define PLATFORM_LINUX 1 #define PLATFORM_BSD 2 #define PLATFORM_DARWIN 3 #ifdef __linux__ #define PLATFORM PLATFORM_LINUX #elif __FreeBSD_kernel__&&__GLIBC__ #define PLATFORM PLATFORM_LINUX #elif __FreeBSD__ #define PLATFORM PLATFORM_BSD #elif __NetBSD__ #define PLATFORM PLATFORM_BSD #elif __APPLE__ && __MACH__ #define PLATFORM PLATFORM_DARWIN #else #error "Unable to determine system (Linux/FreeBSD/NetBSD/Darwin)" #endif #if PLATFORM == PLATFORM_DARWIN #include "darwin_compat.h" #else /* See also: Include/pthreads.pxd */ #include #endif #include #if FUSE_VERSION < 29 #error FUSE version too old, 2.9.0 or newer required #endif #if FUSE_MAJOR_VERSION != 2 #error This version of the FUSE library is not yet supported. #endif llfuse-1.3.3/src/lock.h0000664000175000017500000000057712653313107016376 0ustar nikrationikratio00000000000000/* lock.h - Header file for lock.c Copyright © 2015 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. */ #ifndef _LLFUSE_LOCK_H_ #define _LLFUSE_LOCK_H_ #include int acquire(double timeout); int release(void); int c_yield(int count); void init_lock(void); #endif /* _LLFUSE_LOCK_H_ */ llfuse-1.3.3/src/xattr.h0000644000175000017500000000630312720723015016575 0ustar nikrationikratio00000000000000/* * xattr.h * * Platform-independent interface to extended attributes * * Copyright © 2015 Nikolaus Rath * * This file is part of Python-LLFUSE. This work may be distributed under the * terms of the GNU LGPL. */ #ifndef UNUSED # if defined(__GNUC__) # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)) # define UNUSED __attribute__ ((__unused__)) # else # define UNUSED # endif # else # define UNUSED # endif #endif /* * Linux */ #if PLATFORM == PLATFORM_LINUX #include #define EXTATTR_NAMESPACE_USER 0 #define EXTATTR_NAMESPACE_SYSTEM 0 #define XATTR_NOFOLLOW 0 #define XATTR_NODEFAULT 0 #define XATTR_NOSECURITY 0 static ssize_t getxattr_p (char *path, char *name, void *value, size_t size, UNUSED int namespace) { return getxattr(path, name, value, size); } static int setxattr_p (char *path, char *name, void *value, size_t size, UNUSED int namespace) { return setxattr(path, name, value, size, 0); } /* * FreeBSD & NetBSD */ #elif PLATFORM == PLATFORM_BSD #include #include #include #include #define XATTR_NOFOLLOW 0 #define XATTR_NODEFAULT 0 #define XATTR_NOSECURITY 0 /* FreeBSD doesn't have on operation to only set the attribute if it already exists (XATTR_REPLACE), or only if it does not yet exist (XATTR_CREATE). Setting these values to zero ensures that we can never test positively for them */ #define XATTR_CREATE 0 #define XATTR_REPLACE 0 static ssize_t getxattr_p (char *path, char *name, void *value, size_t size, int namespace) { /* If size > SSIZE_MAX, we cannot determine if we got all the data (because the return value doesn't fit into ssize_t) */ if (size >= SSIZE_MAX) { errno = EINVAL; return -1; } ssize_t ret; ret = extattr_get_file(path, namespace, name, value, size); if (ret > 0 && (size_t) ret == size) { errno = ERANGE; return -1; } return ret; } static int setxattr_p (char *path, char *name, void *value, size_t size, int namespace) { if (size >= SSIZE_MAX) { errno = EINVAL; return -1; } ssize_t ret; ret = extattr_set_file(path, namespace, name, value, size); if (ret < 0) { /* Errno values really ought to fit into int, but better safe than sorry */ if (ret < INT_MIN) return -EOVERFLOW; else return (int) ret; } if ((size_t)ret != size) { errno = ENOSPC; return -1; } return 0; } /* * Darwin */ #elif PLATFORM == PLATFORM_DARWIN #include #define EXTATTR_NAMESPACE_USER 0 #define EXTATTR_NAMESPACE_SYSTEM 0 static ssize_t getxattr_p (char *path, char *name, void *value, size_t size, UNUSED int namespace) { return getxattr(path, name, value, size, 0, 0); } static int setxattr_p (char *path, char *name, void *value, size_t size, UNUSED int namespace) { return setxattr(path, name, value, size, 0, 0); } /* * Unknown system */ #else #error This should not happen #endif llfuse-1.3.3/src/llfuse.pyx0000664000175000017500000001036713202301227017316 0ustar nikrationikratio00000000000000''' llfuse.pxy Copyright © 2013 Nikolaus Rath This file is part of Python-LLFUSE. This work may be distributed under the terms of the GNU LGPL. ''' cdef extern from "llfuse.h": int PLATFORM enum: PLATFORM_LINUX PLATFORM_BSD PLATFORM_DARWIN ########### # C IMPORTS ########### from fuse_lowlevel cimport * from pthread cimport * from posix.stat cimport struct_stat, S_IFMT, S_IFDIR, S_IFREG from posix.types cimport mode_t, dev_t, off_t from libc.stdint cimport uint32_t from libc.stdlib cimport const_char from libc cimport stdlib, string, errno, dirent from libc.errno cimport ETIMEDOUT, EPROTO, EINVAL, EPERM, ENOMSG from posix.unistd cimport getpid from posix.time cimport timespec from posix.signal cimport (sigemptyset, sigaddset, SIG_BLOCK, SIG_SETMASK, siginfo_t, sigaction_t, sigaction, SA_SIGINFO) from cpython.bytes cimport (PyBytes_AsStringAndSize, PyBytes_FromStringAndSize, PyBytes_AsString, PyBytes_FromString, PyBytes_AS_STRING) from cpython.buffer cimport (PyObject_GetBuffer, PyBuffer_Release, PyBUF_CONTIG_RO, PyBUF_CONTIG) cimport cpython.exc cimport cython from cpython.version cimport PY_MAJOR_VERSION from libc cimport signal ###################### # EXTERNAL DEFINITIONS ###################### cdef extern from "lock.h" nogil: int acquire(double timeout) nogil int release() nogil int c_yield(int count) nogil int init_lock() nogil cdef extern from "macros.c" nogil: long GET_BIRTHTIME(struct_stat* buf) long GET_ATIME_NS(struct_stat* buf) long GET_CTIME_NS(struct_stat* buf) long GET_MTIME_NS(struct_stat* buf) long GET_BIRTHTIME_NS(struct_stat* buf) void SET_BIRTHTIME(struct_stat* buf, long val) void SET_ATIME_NS(struct_stat* buf, long val) void SET_CTIME_NS(struct_stat* buf, long val) void SET_MTIME_NS(struct_stat* buf, long val) void SET_BIRTHTIME_NS(struct_stat* buf, long val) void ASSIGN_DARWIN(void*, void*) void ASSIGN_NOT_DARWIN(void*, void*) enum: NOTIFY_INVAL_INODE NOTIFY_INVAL_ENTRY cdef extern from "xattr.h" nogil: int setxattr_p (char *path, char *name, void *value, int size, int namespace) ssize_t getxattr_p (char *path, char *name, void *value, int size, int namespace) enum: EXTATTR_NAMESPACE_SYSTEM EXTATTR_NAMESPACE_USER XATTR_CREATE XATTR_REPLACE XATTR_NOFOLLOW XATTR_NODEFAULT XATTR_NOSECURITY cdef extern from "gettime.h" nogil: int gettime_realtime(timespec *tp) cdef extern from *: # Missing in the Cython provided libc/errno.pxd: enum: EDEADLK ENOATTR cdef extern from "Python.h" nogil: void PyEval_InitThreads() int PY_SSIZE_T_MAX # Actually passed as -D to cc (and defined in setup.py) cdef extern from *: char* LLFUSE_VERSION ################ # PYTHON IMPORTS ################ import os import logging import sys import os.path import threading from pickle import PicklingError if PY_MAJOR_VERSION < 3: from Queue import Queue import contextlib2 as contextlib str_t = bytes else: from queue import Queue str_t = str import contextlib ################## # GLOBAL VARIABLES ################## log = logging.getLogger("llfuse") fse = sys.getfilesystemencoding() cdef object operations cdef object mountpoint_b cdef fuse_session* session = NULL cdef fuse_chan* channel = NULL cdef fuse_lowlevel_ops fuse_ops cdef object exc_info cdef int exit_reason cdef pthread_mutex_t exc_info_mutex init_lock() lock = Lock.__new__(Lock) lock_released = NoLockManager.__new__(NoLockManager) cdef object _notify_queue _notify_queue = Queue(maxsize=1000) # Exported for access from Python code # (in the Cython source, we want ENOATTR to refer # to the C constant, not a Python object) ROOT_INODE = FUSE_ROOT_ID __version__ = LLFUSE_VERSION.decode('utf-8') globals()['ENOATTR'] = ENOATTR ####################### # FUSE REQUEST HANDLERS ####################### include "operations.pxi" include "handlers.pxi" #################### # INTERNAL FUNCTIONS #################### include "misc.pxi" #################### # FUSE API FUNCTIONS #################### include "fuse_api.pxi" llfuse-1.3.3/src/gettime.h0000664000175000017500000000170312653314441017076 0ustar nikrationikratio00000000000000/* * gettime.h * * Platform-independent interface to system clock * * Copyright © 2015 Nikolaus Rath * * This file is part of Python-LLFUSE. This work may be distributed under the * terms of the GNU LGPL. */ /* * Linux */ #if PLATFORM == PLATFORM_LINUX #include static int gettime_realtime(struct timespec *tp) { return clock_gettime(CLOCK_REALTIME, tp); } /* * FreeBSD & NetBSD */ #elif PLATFORM == PLATFORM_BSD #include static int gettime_realtime(struct timespec *tp) { return clock_gettime(CLOCK_REALTIME, tp); } /* * Darwin */ #elif PLATFORM == PLATFORM_DARWIN #include static int gettime_realtime(struct timespec *tp) { struct timeval tv; int res; res = gettimeofday(&tv, NULL); if(res != 0) return -1; tp->tv_sec = tv.tv_sec; tp->tv_nsec = tv.tv_usec * 1000; return 0; } /* * Unknown system */ #else #error This should not happen #endif