Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • L libsoup
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 171
    • Issues 171
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • 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
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • GNOMEGNOME
  • libsoup
  • Issues
  • #178
Closed
Open
Issue created Dec 18, 2019 by Tristan Partin@tristan957

Adding a SoupLogger with SOUP_LOGGER_LEVEL_NONE to a SoupSession causes two newlines to be printed to the console in my application

The logger is instantiated like so

g_autoptr(SoupLogger) logger = soup_logger_new(SOUP_LOGGER_LOG_NONE, -1);

The session is instantiated like so

g_autoptr(SoupSession) session = soup_session_new_with_options(SOUP_SESSION_MAX_CONNS,
		max_connections, SOUP_SESSION_USER_AGENT, user_agent->str, SOUP_SESSION_ADD_FEATURE_BY_TYPE,
		SOUP_TYPE_CONTENT_SNIFFER, SOUP_SESSION_ADD_FEATURE, SOUP_SESSION_FEATURE(logger), NULL);

When I remove the logger feature from the session constructor, no newlines are printed to the console.

My small amount of debugging leads me to the following conclusion. Attached is a sample of SOUP_LOGGER_LOG_MINIMAL. In it you will notice two things. Two lines with 2 spaces to begin the lines although they are empty lines (4, 8).

out.txt

Here is a sample output of SOUP_LOGGER_LOG_NONE. In it you will notice that lines one and two both have two spaces preceding them. I believe these are the same lines as 4 and 8 from the previous file.

out.txt

Version of libsoup: 2.68.3 (Fedora default)

Edited Dec 19, 2019 by Tristan Partin
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking