Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Register
  • Sign in
  • pygobject pygobject
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 303
    • Issues 303
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 32
    • Merge requests 32
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • pygobjectpygobject
  • Issues
  • #193
Closed
Open
Issue created Apr 06, 2018 by Victor Malov@likern

Segfault in Python application with custom GLib.Source

When I run application I sometimes get the following unexpected behaviors:

  1. Come across with SEGFAULT of application.
  2. See on console error "AttributeError: 'socket' object has no attribute 'check'"
  3. See on console error "AttributeError: 'socket' object has no attribute 'prepare'"

My analysis showed that the problem probably lies into pygobject library itself.

I think the problem is in gi/pygi-source.c in functions pyg_source_prepare and pyg_source_check. When is called PyObject_CallMethod(pysource->obj, "check", NULL); pysource->obj is expected to be object. But it turns out it's a "socket" which doesn't have these attributes.

Screenshot_from_2018-04-02_20-28-32 Screenshot_from_2018-04-02_20-33-59 application.py

Edited Apr 06, 2018 by Christoph Reiter
Assignee
Assign to
Time tracking