svn commit: samba r3281 - in branches/SAMBA_4_0/source/build/pidl: .
tridge at samba.org
tridge at samba.org
Wed Oct 27 04:33:36 GMT 2004
Author: tridge
Date: 2004-10-27 04:33:36 +0000 (Wed, 27 Oct 2004)
New Revision: 3281
WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba&path=/branches/SAMBA_4_0/source/build/pidl&rev=3281&nolog=1
Log:
some compilers can't handle empty structures, so for empty IDL
structures generate a single _empty_ element in the header
Modified:
branches/SAMBA_4_0/source/build/pidl/header.pm
Changeset:
Modified: branches/SAMBA_4_0/source/build/pidl/header.pm
===================================================================
--- branches/SAMBA_4_0/source/build/pidl/header.pm 2004-10-27 03:50:52 UTC (rev 3280)
+++ branches/SAMBA_4_0/source/build/pidl/header.pm 2004-10-27 04:33:36 UTC (rev 3281)
@@ -75,11 +75,17 @@
my($name) = shift;
$res .= "\nstruct $name {\n";
$tab_depth++;
+ my $el_count=0;
if (defined $struct->{ELEMENTS}) {
foreach my $e (@{$struct->{ELEMENTS}}) {
HeaderElement($e);
+ $el_count++;
}
}
+ if ($el_count == 0) {
+ # some compilers can't handle empty structures
+ $res .= "\tchar _empty_;\n";
+ }
$tab_depth--;
$res .= "}";
}
More information about the samba-cvs
mailing list