#binmode $fh ;\r
my $str = '';\r
while (<$fh>) {\r
- if ( /^\/\/\$\$CDS-header\$\$/ ) {\r
- $str .= \r
-"/*\r
- This file is a part of libcds - Concurrent Data Structures library\r
-\r
- (C) Copyright Maxim Khizhinsky (libcds.dev\@gmail.com) 2006-$year\r
-\r
- Source code repo: http://github.com/khizmax/libcds/\r
- Download: http://sourceforge.net/projects/libcds/files/\r
- \r
- Redistribution and use in source and binary forms, with or without\r
- modification, are permitted provided that the following conditions are met:\r
-\r
- * Redistributions of source code must retain the above copyright notice, this\r
- list of conditions and the following disclaimer.\r
-\r
- * Redistributions in binary form must reproduce the above copyright notice,\r
- this list of conditions and the following disclaimer in the documentation\r
- and/or other materials provided with the distribution.\r
-\r
- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\r
- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\r
- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\r
- DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\r
- FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\r
- DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\r
- SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\r
- CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\r
- OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\r
- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. \r
-*/\n" ;\r
- }\r
- else {\r
- $nTabsFound += $_ =~ s/\t/ /g;\r
- $_ =~ s/\s+$//;\r
- $_ =~ s/\s+;$/;/;\r
- $_ =~ s/\)\s+\)/\)\)/g;\r
- $str .= $_ ;\r
- $str .= "\n" ;\r
- }\r
+ $nTabsFound += $_ =~ s/\t/ /g;\r
+ $_ =~ s/\s+$//;\r
+ $_ =~ s/\s+;$/;/;\r
+ $_ =~ s/\)\s+\)/\)\)/g;\r
+ $str .= $_ ;\r
+ $str .= "\n" ;\r
}\r
close $fh;\r
\r