public inbox for [email protected]  
help / color / mirror / Atom feed
pgadmin4: sleep api
2+ messages / 2 participants
[nested] [flat]

* pgadmin4: sleep api
@ 2015-10-28 22:59 Prasad Somwanshi <[email protected]>
  2015-10-29 10:27 ` Re: pgadmin4: sleep api Dave Page <[email protected]>
  0 siblings, 1 reply; 2+ messages in thread

From: Prasad Somwanshi @ 2015-10-28 22:59 UTC (permalink / raw)
  To: pgadmin-hackers


-- 
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers


Attachments:

  [text/x-patch] sleep.patch (629B, 2-sleep.patch)
  download | inline diff:


diff --git a/runtime/pgAdmin4.cpp b/runtime/pgAdmin4.cpp
--- a/runtime/pgAdmin4.cpp
+++ b/runtime/pgAdmin4.cpp
@@ -61,7 +61,7 @@ int main(int argc, char * argv[])
 
     // This is a hack. Wait a second and then check to see if the server thread
     // is still running. If it's not, we probably had a startup error
-    sleep(1);
+    QThread::sleep(1);
 
     // Any errors?
     if (server->isFinished() || server->getError().length() > 0)
@@ -108,7 +108,7 @@ int main(int argc, char * argv[])
             exit(1);
         }
 
-        sleep(1);
+        QThread::sleep(1);
     }
 
     // Create & show the main window


^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: pgadmin4: sleep api
  2015-10-28 22:59 pgadmin4: sleep api Prasad Somwanshi <[email protected]>
@ 2015-10-29 10:27 ` Dave Page <[email protected]>
  0 siblings, 0 replies; 2+ messages in thread

From: Dave Page @ 2015-10-29 10:27 UTC (permalink / raw)
  To: Prasad Somwanshi <[email protected]>; +Cc: pgadmin-hackers

Thanks - patch applied.

On Wed, Oct 28, 2015 at 11:59 PM, Prasad Somwanshi <[email protected]> wrote:
> Hi,
>
> sleep api used in pgAdmin4.cpp doesn't seem cross-platform(used from POSIX
> specific C header). Either need to be replaced by C++11 equivalent or Qt
> one. QThread::sleep seem appropriate to me.
>
> thanks and regards,
> Prasad Somwanshi
>
>
> --
> Sent via pgadmin-hackers mailing list ([email protected])
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgadmin-hackers
>



-- 
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2015-10-29 10:27 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-10-28 22:59 pgadmin4: sleep api Prasad Somwanshi <[email protected]>
2015-10-29 10:27 ` Dave Page <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox