Skip to content

sentry_init fails if database path on different drive #281

@FredrikLundkvist

Description

@FredrikLundkvist

Hi,

I have two related issues:

  1. The database path defaults to ".sentry-native" in the current folder (app folder).
    This is not useful on Mac/Windows, since these folders are not writable.
    A better default would perhaps be some cache/local app data folder, eg:
    Caches folder on Mac (URLForDirectory:NSCachesDirectory, inDomains:NSUserDomainMask),
    %localappdata% on Windows (SHGetKnownFolderPath(FOLDERID_LocalAppData))

  2. I use those folders in our app, but then I run into another problem, on Windows.
    The %localappdata% is usually on C:, and if the user installs our app (and sentry.dll)
    on another drive, sentry_init() fails.

Also, just curious:
3. Is the database needed if you build "standalone" with no backend?
We currently do that, but will probably change to use a backend later, so not a big issue.

Thanks,
Fredrik

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions