Bug 393304 - getxattr takes 6 parameters in macOS
Summary: getxattr takes 6 parameters in macOS
Status: RESOLVED FIXED
Alias: None
Product: frameworks-kio
Classification: Frameworks and Libraries
Component: general (other bugs)
Version First Reported In: 5.45.0
Platform: Homebrew (macOS) macOS
: NOR normal
Target Milestone: ---
Assignee: David Faure
URL: https://github.com/KDE-mac/homebrew-k...
Keywords:
Depends on:
Blocks:
 
Reported: 2018-04-19 18:09 UTC by Yurii Kolesnykov
Modified: 2018-04-19 22:01 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.46
Sentry Crash Report:


Attachments
initial patch (1.53 KB, patch)
2018-04-19 18:09 UTC, Yurii Kolesnykov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yurii Kolesnykov 2018-04-19 18:09:32 UTC
Created attachment 112124 [details]
initial patch

We had written patch for kio in our homebrew tap. See attachment. It doesn't tested on other platforms.
Comment 1 Yurii Kolesnykov 2018-04-19 18:12:50 UTC
file_unix.cpp:421:19: error: no matching function for call to 'getxattr'
    auto length = getxattr(filenameEncoded.data(), attrName, nullptr, 0);
                  ^~~~~~~~
/usr/include/sys/xattr.h:61:9: note: candidate function not viable: requires 6 arguments, but 4 were provided
ssize_t getxattr(const char *path, const char *name, void *value, size_t size, u_int32_t position, int options);
        ^
file_unix.cpp:427:14: error: no matching function for call to 'getxattr'
    length = getxattr(filenameEncoded.data(), attrName, strAttr, xattr_size);
             ^~~~~~~~
Comment 2 Yurii Kolesnykov 2018-04-19 18:13:45 UTC
See commits d7cce9937d5e9af2753fadb82d11f308b58bb8fa and f1ab805c4ebcea24f0b84b785bc56515060e5eb2
Comment 3 Nate Graham 2018-04-19 18:17:18 UTC
Thank you very much for the patch! Please submit it using http://phabricator.kde.org/.

Here is the documentation: https://community.kde.org/Infrastructure/Phabricator
Comment 4 Yurii Kolesnykov 2018-04-19 21:37:24 UTC
https://phabricator.kde.org/D12365
Comment 5 Nate Graham 2018-04-19 22:01:07 UTC
Git commit 87e9e3b68fdc9b13567e40f7e02e154520bc62c4 by Nathaniel Graham, on behalf of Yurii Kolesnykov.
Committed on 19/04/2018 at 21:53.
Pushed by ngraham into branch 'master'.

getxattr takes 6 parameters in macOS

Summary:
Fix the xattr failure on macOS.
FIXED-IN: 5.46

Reviewers: ngraham

Reviewed By: ngraham

Subscribers: #frameworks

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D12365

M  +8    -0    src/ioslaves/file/file_unix.cpp
M  +3    -0    src/widgets/kpropertiesdialog.cpp

https://commits.kde.org/kio/87e9e3b68fdc9b13567e40f7e02e154520bc62c4