Skip to content
Permalink
Browse files

fix about box (followup 0b940ca, fixes #14832)

  • Loading branch information
jef-n committed May 17, 2016
1 parent aa66bc6 commit 04176350ec66acc1d36b80134901acd3fbeed834
Showing with 3 additions and 3 deletions.
  1. +2 −2 src/app/qgsabout.cpp
  2. +1 −1 src/core/qgsmaplayer.cpp
@@ -87,7 +87,7 @@ void QgsAbout::init()
{
line = stream.readLine(); // line of text excluding '\n'
//ignore the line if it starts with a hash....
if ( line.at( 0 ) == '#' )
if ( !line.isEmpty() && line.at( 0 ) == '#' )
continue;
QStringList myTokens = line.split( '\t', QString::SkipEmptyParts );
lines << myTokens[0];
@@ -119,7 +119,7 @@ void QgsAbout::init()
{
line = stream.readLine(); // line of text excluding '\n'
//ignore the line if it starts with a hash....
if ( line.at( 0 ) == '#' )
if ( !line.isEmpty() && line.at( 0 ) == '#' )
continue;
lines += line;
}
@@ -1026,7 +1026,7 @@ QString QgsMapLayer::capitaliseLayerName( const QString& name )

QString layerName( name );

if ( capitaliseLayerName )
if ( capitaliseLayerName && !layerName.isEmpty() )
layerName = layerName.at( 0 ).toUpper() + layerName.mid( 1 );

return layerName;

1 comment on commit 0417635

@nyalldawson

This comment has been minimized.

Copy link
Collaborator

@nyalldawson nyalldawson commented on 0417635 May 17, 2016

Thanks @jef-n !

Please sign in to comment.
You can’t perform that action at this time.