# LOG() macro fails if message is a simple std::string

XMLWordPrintable

#### Details

• Type: Bug
• Status: Won't Fix
• Resolution: Done
• Fix Version/s: None
• Component/s:
• Labels:
None
• Story Points:
1.5
• Sprint:
DB_S15_06, DB_S15_07, DB_S15_08, DB_W16_09
• Team:
Data Access and Database

#### Description

lsst:log LOG() macro crash with fatal error if message is a simple string.

#### Activity

Hide
Tim Jenness added a comment -

Shall I look at this since I'm meant to be looking at the log package anyhow?

Show
Tim Jenness added a comment - Shall I look at this since I'm meant to be looking at the log package anyhow?
Hide
Jacek Becla added a comment -

That'd be welcome

Show
Jacek Becla added a comment - That'd be welcome
Hide
Tim Jenness added a comment -

Fabrice Jammes can you tell me how to trigger this? Naively using a std::string as an argument to LOG causes a compiler error for me as it can't find a valid constructor for a std::string.

Show
Tim Jenness added a comment - Fabrice Jammes can you tell me how to trigger this? Naively using a std::string as an argument to LOG causes a compiler error for me as it can't find a valid constructor for a std::string .
Hide
Fabrice Jammes added a comment -

Hi Tim Jenness,

Sorry but I can't reproduce thos problem no more. As far as I can remember I met this kind of problem:

 LOGF(LOG_GET("testLogger"), LOG_LVL_INFO, "This was crashing the program if no parameters where provided"); // but LOGF_DEBUG("This was working"); 

Both of them seems to works now so I propose to set this ticket state to "won't fix"?

Cheers,

Show
Fabrice Jammes added a comment - Hi Tim Jenness , Sorry but I can't reproduce thos problem no more. As far as I can remember I met this kind of problem: LOGF(LOG_GET( "testLogger" ), LOG_LVL_INFO, "This was crashing the program if no parameters where provided" ); // but LOGF_DEBUG( "This was working" ); Both of them seems to works now so I propose to set this ticket state to "won't fix"? Cheers,
Hide
Tim Jenness added a comment -

Closed as we can no longer reproduce. Re-open if we do demonstrate it again.

Show
Tim Jenness added a comment - Closed as we can no longer reproduce. Re-open if we do demonstrate it again.

#### People

Assignee:
Tim Jenness
Reporter:
Fabrice Jammes
Watchers:
Fabrice Jammes, Jacek Becla, Kian-Tat Lim, Tim Jenness