Skip to content

Commit

Permalink
fix: display real caller data insteadof log call
Browse files Browse the repository at this point in the history
  • Loading branch information
benoitdm-oslandia committed Jan 24, 2025
1 parent 1d379ea commit f7a99bc
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/server/services/wfs/qgswfsparameters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -364,8 +364,8 @@ namespace QgsWfs
return version;
}

void QgsWfsParameters::log( const QString &msg ) const
void QgsWfsParameters::log( const QString &msg, const char *file, const char *function, int line ) const
{
QgsMessageLog::logMessage( msg, "Server", Qgis::MessageLevel::Info );
QgsMessageLog::logMessage( msg, "Server", Qgis::MessageLevel::Info, true, file, function, line );
}
} // namespace QgsWfs
2 changes: 1 addition & 1 deletion src/server/services/wfs/qgswfsparameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,7 @@ namespace QgsWfs
bool loadParameter( const QString &key, const QString &value ) override;
void save( const QgsWfsParameter &parameter );

void log( const QString &msg ) const;
void log( const QString &msg, const char *file = __builtin_FILE(), const char *function = __builtin_FUNCTION(), int line = __builtin_LINE() ) const;

QList<QgsProjectVersion> mVersions;
QMap<QgsWfsParameter::Name, QgsWfsParameter> mWfsParameters;
Expand Down
4 changes: 2 additions & 2 deletions src/server/services/wms/qgswmsparameters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2056,9 +2056,9 @@ namespace QgsWms
return mWmsParameters.value( QgsWmsParameter::WMTVER ).toString();
}

void QgsWmsParameters::log( const QString &msg ) const
void QgsWmsParameters::log( const QString &msg, const char *file, const char *function, int line ) const
{
QgsMessageLog::logMessage( msg, QStringLiteral( "Server" ), Qgis::MessageLevel::Info );
QgsMessageLog::logMessage( msg, QStringLiteral( "Server" ), Qgis::MessageLevel::Info, true, file, function, line );
}

void QgsWmsParameters::raiseError( const QString &msg ) const
Expand Down
2 changes: 1 addition & 1 deletion src/server/services/wms/qgswmsparameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -1530,7 +1530,7 @@ namespace QgsWms
QgsWmsParameter idParameter( QgsWmsParameter::Name name, int id ) const;

void raiseError( const QString &msg ) const;
void log( const QString &msg ) const;
void log( const QString &msg, const char *file = __builtin_FILE(), const char *function = __builtin_FUNCTION(), int line = __builtin_LINE() ) const;

QgsWmsParametersExternalLayer externalLayerParameter( const QString &name ) const;

Expand Down
4 changes: 2 additions & 2 deletions src/server/services/wmts/qgswmtsparameters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -292,8 +292,8 @@ namespace QgsWmts
return version;
}

void QgsWmtsParameters::log( const QString &msg ) const
void QgsWmtsParameters::log( const QString &msg, const char *file, const char *function, int line ) const
{
QgsMessageLog::logMessage( msg, "Server", Qgis::MessageLevel::Info );
QgsMessageLog::logMessage( msg, "Server", Qgis::MessageLevel::Info, true, file, function, line );
}
} // namespace QgsWmts
2 changes: 1 addition & 1 deletion src/server/services/wmts/qgswmtsparameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ namespace QgsWmts
bool loadParameter( const QString &key, const QString &value ) override;
void save( const QgsWmtsParameter &parameter );

void log( const QString &msg ) const;
void log( const QString &msg, const char *file = __builtin_FILE(), const char *function = __builtin_FUNCTION(), int line = __builtin_LINE() ) const;

QList<QgsProjectVersion> mVersions;
QMap<QgsWmtsParameter::Name, QgsWmtsParameter> mWmtsParameters;
Expand Down

0 comments on commit f7a99bc

Please sign in to comment.