[vlc-devel] commit: No need to create an object to handle the lock is such a simple case. ( Rémi Duraffort )

Laurent Aimar fenrir at via.ecp.fr
Thu Jun 18 14:08:03 CEST 2009


Hi,

On Thu, Jun 18, 2009, git version control wrote:
> vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Thu Jun 18 13:47:13 2009 +0200| [f001a156e79ba8e9c2c4f2b62330b9e155c1ec33] | committer: Rémi Duraffort 
> 
> No need to create an object to handle the lock is such a simple case.
 I don't really see the rationnal behind that change, the solution with the
object has 0 cost (cpu/memory, as long as the compilator is not uterly dumb).
 It is a common practice with c++ and mandatory(?) with exceptions.

> --- a/modules/audio_filter/spatializer/spatializer.cpp
> +++ b/modules/audio_filter/spatializer/spatializer.cpp
> @@ -9,19 +9,19 @@
>   *
>   * Mentor : Jean-Baptiste Kempf <jb at videolan.org>
>   *
> - * This program is free software; you can redistribute it and/or modify
> - * it under the terms of the GNU General Public License as published by
> - * the Free Software Foundation; either version 2 of the License, or
> - * (at your option) any later version.
> + * This program is free software; you can redistribute it and/or modify it
> + * under the terms of the GNU General Public License as published by the Free
> + * Software Foundation; either version 2 of the License, or (at your option)
> + * any later version.
>   *
> - * This program is distributed in the hope that it will be useful,
> - * but WITHOUT ANY WARRANTY; without even the implied warranty of
> - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
> - * GNU General Public License for more details.
> + * This program is distributed in the hope that it will be useful, but WITHOUT
> + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
> + * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
> + * more details.
>   *
> - * You should have received a copy of the GNU General Public License
> - * along with this program; if not, write to the Free Software
> - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
> + * You should have received a copy of the GNU General Public License along with
> + * this program; if not, write to the Free Software Foundation, Inc., 51
> + * Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
>   *****************************************************************************/
>  
>  /*****************************************************************************
> @@ -49,7 +49,7 @@ static void Close( vlc_object_t * );
>  
>  #define ROOMSIZE_TEXT N_("Room size")
>  #define ROOMSIZE_LONGTEXT N_("Defines the virtual surface of the room" \
> -                                "emulated by the filter." )
> +                             "emulated by the filter." )
>  
>  #define WIDTH_TEXT N_("Room width")
>  #define WIDTH_LONGTEXT N_("Width of the virtual room")
> @@ -90,21 +90,6 @@ struct aout_filter_sys_t
>  
>  };
 But way worse, do NOT mix (especially large) cosmetics with code modifications.
It make non cosmetics modifications harder to revert.

-- 
fenrir



More information about the vlc-devel mailing list