[Nagiosplug-devel] [ nagiosplug-Bugs-1583467 ] C++ comments used in C code

SourceForge.net noreply at sourceforge.net
Tue Oct 24 12:24:01 CEST 2006


Bugs item #1583467, was opened at 2006-10-24 12:24
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1583467&group_id=29880

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Compilation
Group: Release (specify)
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Markus Baertschi (markus_b)
Assigned to: Nobody/Anonymous (nobody)
Summary: C++ comments used in C code

Initial Comment:
While compiling nagios-plugins-1.4.4 on AIX using the
IBM compiler I'm stumbling over two cases where
C++-style comments '//' in stead of proper C comments
are used '/*  */'. The compiler flags these as Syntax
error as this comment style is not allowed in ANSI C.

Replacing the // with /* */ fixes the problem and all
compiles fine.

Here the 
"check_disk.c", line 639.3: 1506-046 (S) Syntax error.
639:   // return;
"check_http.c", line 277.7: 1506-046 (S) Syntax error.
277:   // asprintf (&http_opt_headers, "%s", optarg);

Markus


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397597&aid=1583467&group_id=29880




More information about the Devel mailing list