This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 255149 - printf("%s", string.c_str()) wrongly marked as error
Summary: printf("%s", string.c_str()) wrongly marked as error
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: -- Other -- (show other bugs)
Version: 8.1
Hardware: All All
: P3 normal (vote)
Assignee: danilasergeyev
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-09 19:33 UTC by Alexander Simon
Modified: 2015-09-15 08:08 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Simon 2015-09-09 19:33:02 UTC
Code example:

#include <stdio.h>
#include <string>
int main(int argc, char**argv) {
    std::string s("string");
    printf("%s", s.c_str());// IDE suggest change %s -> %p 
    return 0;
}
Comment 1 danilasergeyev 2015-09-14 17:05:06 UTC
fixed, change set:
https://hg.netbeans.org/cnd-main/rev/ad8c73ee7ae8
Comment 2 Quality Engineering 2015-09-15 01:24:10 UTC
Integrated into 'main-silver', will be available in build *201509150002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/ad8c73ee7ae8
User: Danila Sergeyev <danilasergeyev@netbeans.org>
Log: fix bug #255149 printf("%s", string.c_str()) wrongly marked as error