Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorder method order to avoid int-conversion compilation issue #161

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fweimer-rh
Copy link

Without this change, GCC 14 will fail compilation with an error:

XADRAR5Parser.m: In function ‘+[XADRAR5Parser recognizeFileWithHandle:firstBytes:name:]’: XADRAR5Parser.m:79:5: warning: ‘XADRAR5Parser’ may not respond to ‘+signatureLocationInData:’
   79 |     off_t signatureLocation = [self signatureLocationInData:data];
      |     ^~~~~
XADRAR5Parser.m:79:5: warning: (messages without a matching method signature will be assumed to return ‘id’ and accept ‘...’ as arguments)
XADRAR5Parser.m:79:31: error: initialization of ‘off_t’ {aka ‘long int’} from ‘id’ makes integer from pointer without a cast
   79 |     off_t signatureLocation = [self signatureLocationInData:data];
      |                               ^

Related to:

Without this change, GCC 14 will fail compilation with an error:

XADRAR5Parser.m: In function ‘+[XADRAR5Parser recognizeFileWithHandle:firstBytes:name:]’:
XADRAR5Parser.m:79:5: warning: ‘XADRAR5Parser’ may not respond to ‘+signatureLocationInData:’
   79 |     off_t signatureLocation = [self signatureLocationInData:data];
      |     ^~~~~
XADRAR5Parser.m:79:5: warning: (messages without a matching method signature will be assumed to return ‘id’ and accept ‘...’ as arguments)
XADRAR5Parser.m:79:31: error: initialization of ‘off_t’ {aka ‘long int’} from ‘id’ makes integer from pointer without a cast
   79 |     off_t signatureLocation = [self signatureLocationInData:data];
      |                               ^
gnomesysadmins pushed a commit to GNOME/file-roller that referenced this pull request Sep 12, 2024
The repo MacPaw/unar is unmaintained but it is just the shallow clone of
the repos XADMaster and universal-detector. The patch comes from
MacPaw/XADMaster#161.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant